assertEquals($message, $e->getMessage()); return; } $this->fail('Expected PHPParser_Error'); } public function provideTestError() { return array( array('lex($value, $line, $docComment)) { $token = array_shift($tokens); $this->assertEquals($token[0], $id); $this->assertEquals($token[1], $value); $this->assertEquals($token[2], $line); $this->assertEquals($token[3], $docComment); } } public function provideTestLex() { return array( // tests conversion of closing PHP tag and drop of whitespace, comments and opening tags array( 'plaintext', array( array(PHPParser_Parser::T_STRING, 'tokens', 1, null), array(ord(';'), '?>', 1, null), array(PHPParser_Parser::T_INLINE_HTML, 'plaintext', 1, null), ) ), // tests line numbers array( 'lex()); $this->assertEquals($lexer->handleHaltCompiler(), $remaining); $this->assertEquals(0, $lexer->lex()); } public function provideTestHaltCompiler() { return array( array('Remaining Text', 'Remaining Text'), //array('