public function testEscapeFullText() { $session = $this->getMockBuilder('PHPCR\\SessionInterface')->getMock(); $dm = DocumentManager::create($session); $string = $dm->escapeFullText('Some{String}Wit"h[]Illegal^^^Chara\\cte?rs:!'); $this->assertEquals($string, 'Some\\{String\\}Wit"h\\[\\]Illegal\\^\\^\\^Chara\\cte\\?rs\\:\\!'); }