public function setUp() { parent::setUp(); $this->node = $this->prophesize('PHPCR\\NodeInterface'); $this->node1 = $this->prophesize('PHPCR\\NodeInterface'); $this->node2 = $this->prophesize('PHPCR\\NodeInterface'); }
public function setUp() { parent::setUp(); $this->documentManager = $this->prophesize(DocumentManagerInterface::class); $this->managerRegistry = $this->prophesize(ManagerRegistry::class); $this->childrenCollection = $this->prophesize(ChildrenCollection::class); $this->uow = $this->prophesize(UnitOfWork::class); $this->document = new \stdClass(); $this->child1 = new \stdClass(); // because Prophecy doesn't care much about object IDs... $this->child2 = new stdClass2(); $this->node1 = $this->prophesize(NodeInterface::class); $this->node2 = $this->prophesize(NodeInterface::class); $this->managerRegistry->getManager()->willReturn($this->documentManager); $this->documentManager->getUnitOfWork()->willReturn($this->uow->reveal()); }