public function setUp() { $session = $this->getMockBuilder('PHPCR\\SessionInterface')->getMock(); $this->dm = \Doctrine\ODM\PHPCR\DocumentManager::create($session); }