/** * Test an empty ItemPhoto Entity */ public function testEmptyItemPhoto() { $itemPhoto = new ItemPhoto(); $this->assertNull($itemPhoto->getId()); $this->assertNull($itemPhoto->getImageName()); $this->assertNull($itemPhoto->getItem()); $this->assertNull($itemPhoto->getImageFile()); }
/** * Add photo * * @param ItemPhoto $photo Photo * * @return $this */ public function addPhoto(ItemPhoto $photo) { $this->photos->add($photo->setItem($this)); return $this; }