*/ public function testPrettyPrint($name, $code, $dump) { $parser = new PHPParser_Parser(new PHPParser_Lexer_Emulative); $prettyPrinter = new PHPParser_PrettyPrinter_Zend; $stmts = $parser->parse($code); $this->assertEquals( $this->canonicalize($dump), $this->canonicalize($prettyPrinter->prettyPrint($stmts)), $name ); } public function provideTestPrettyPrint() { return $this->getTests(dirname(__FILE__) . '/../../code/prettyPrinter', 'test'); } }