/** */ public function testLoad() { $id = 1; /** @var EntityInterface|ObjectProphecy $entity */ $entity = $this->prophesize('AppBundle\\Entity\\EntityInterface'); $this->repository->find($id)->willReturn($entity->reveal())->shouldBeCalledTimes(1); $this->assertSame($entity->reveal(), $this->manager->load($id)); }
/** * @param int $id * * @return EntityInterface */ public function load($id) { return $this->repository->find($id); }