Example #1
0
 /**
  * @test
  */
 public function removeImageFromObjectStorageHoldingImage()
 {
     $image = new \TYPO3\CMS\Extbase\Domain\Model\FileReference();
     $imageObjectStorageMock = $this->getMock('TYPO3\\CMS\\Extbase\\Persistence\\ObjectStorage', array('detach'), array(), '', FALSE);
     $imageObjectStorageMock->expects($this->once())->method('detach')->with($this->equalTo($image));
     $this->inject($this->subject, 'image', $imageObjectStorageMock);
     $this->subject->removeImage($image);
 }