Example #1
0
 /**
  * @test
  */
 public function removeCategoryFromObjectStorageHoldingCategory()
 {
     $category = new \JS\JsEvent\Domain\Model\Category();
     $categoryObjectStorageMock = $this->getMock('TYPO3\\CMS\\Extbase\\Persistence\\ObjectStorage', array('detach'), array(), '', FALSE);
     $categoryObjectStorageMock->expects($this->once())->method('detach')->with($this->equalTo($category));
     $this->inject($this->subject, 'category', $categoryObjectStorageMock);
     $this->subject->removeCategory($category);
 }