Sulu\Bundle\MediaBundle\Behat\MediaContext::getLastMediaCollection PHP Method

getLastMediaCollection() private method

Return the last media collection that was created in this context.
private getLastMediaCollection ( ) : Collection
return Sulu\Bundle\MediaBundle\Entity\Collection
    private function getLastMediaCollection()
    {
        if (!$this->lastCollection) {
            throw new \InvalidArgumentException('No media collection has previously been created in this session, cannot use getLastMediaCollection');
        }
        return $this->lastCollection;
    }