Nikita Popov
f2b7a31509
Rename ParserInterface to Parser
...
And drop the alias of Parser to Parser\Php5.
2015-06-20 11:47:25 +02:00
Nikita Popov
d8312a09a3
Split parsing tests into code tests and other stuff
...
And run the other stuff against Php5 and Php7 parsers.
Also move canonicalize() from CodeTestAbstract into a free-standing
function.
2015-06-20 11:44:29 +02:00
Nikita Popov
602b9807eb
Import some UVS tests
2015-06-13 15:42:09 +02:00
Nikita Popov
f372a4c4ab
Move modeline handling into CodeTestAbstract
2015-06-13 15:10:46 +02:00
Nikita Popov
d18dcc0c7f
Implement UVS
2015-06-13 14:59:24 +02:00
Nikita Popov
74c57eef0e
Test PHP 5 and PHP 7 parsers
...
At this point they should return the same result.
2015-06-13 13:56:45 +02:00
Nikita Popov
9caa51b3a5
Add some more tests
2015-05-01 20:18:04 +02:00
Nikita Popov
0731b47655
Don't distinguish test-fail / test
...
With error recovery this is fluid. Using .test for everything.
2015-04-30 17:45:36 +02:00
Nikita Popov
3b7d8e8b5d
Enable basic error recovery
...
Adding only a single recovery rule for now.
The API is now:
* throwOnError parser option must be disabled.
* List of Errors is available through $parser->getErrors(). This
method is available either way.
* If no recovery is possible $parser->parse() will return null.
(Obviously only if throwOnError is disabled).
2015-04-30 17:41:57 +02:00
Nikita Popov
611fa5c7f1
Test parser position information (syntax errors)
2015-04-18 13:27:57 +02:00
Nikita Popov
3028bc8081
And make it work on PHP 5 as well...
2015-02-26 16:40:21 +01:00
Nikita Popov
91295a0790
Make tests compatible with PHP 7
...
When parsing on PHP 7 we will no longer be able to deal with
code that contains invalid octal literals. Currently we'll fatal,
after engine exceptions land we'll throw an exception instead.
2015-02-26 16:26:29 +01:00
Nikita Popov
0a445c7656
Test lexer returning invalid token
2015-01-18 00:11:10 +01:00
Nikita Popov
e69c9ee38c
Fix attribute assigment test with crlf newlines
2014-12-19 17:28:22 +01:00
Nikita Popov
894c3f787d
Add test for attribute assignment by parser
...
Weird that this wasn't tested yet...
2014-12-19 00:37:38 +01:00
nikic
66fd29cb58
Use stricter assertions where possible
2014-09-30 20:38:09 +02:00
nikic
f82862ec9c
Port library to use namespaces, with BC for old names
2014-02-06 20:29:35 +01:00