/** * @dataProvider getInvalidPostfixData * @expectedException \Symfony\Component\ExpressionLanguage\SyntaxError */ public function testParseWithInvalidPostfixData($expr, $names = array()) { $lexer = new Lexer(); $parser = new Parser(array()); $parser->parse($lexer->tokenize($expr), $names); }
/** * @dataProvider getParseData */ public function testParse($node, $expression, $names = array()) { $lexer = new Lexer(); $parser = new Parser(array()); $this->assertEquals($node, $parser->parse($lexer->tokenize($expression), $names)); }