Nikita Popov
9484baf8f8
Make compatible with PhpUnit 8
2019-06-23 15:03:40 +02:00
Lars Moelleken
b7e6361536
updates via "rectorphp/rector" ( #573 )
...
- "global" -> remove unused "use" statements
- "phpunit" -> fix "@covers" comments
- "phpunit" -> replace "->will($this->returnValue()" with "->willReturn()"
- "UseTest.php" -> add missing namespace
- "composer.json" -> use "autoload-dev"
- remove -> "require_once" usage in the tests (use autoload-dev via composer.json)
-> most of the changes are done automatically by "https://github.com/rectorphp/rector "
2019-01-19 11:18:00 +01:00
Maks Rafalko
dc323458b4
Add new constant to be returned from enterNode() to not traverse current and child nodes ( #536 )
...
* Add new constant to be returned from enterNode() to not travers current node for subsequent visitors and skip children traversing
* Allow visitors to replace nodes in leaveNode() when DONT_TRAVERSE_CURRENT_AND_CHILDREN is used
2018-10-08 22:26:00 +02:00
Tomáš Votruba
d638dd9b25
Use methods instead of annotations for expected exceptions ( #533 )
2018-09-22 10:43:54 +02:00
Nikita Popov
6aba7624ed
Add replacement sanity check in traverser
2018-03-03 13:22:36 +01:00
Nikita Popov
c7ada124d0
[CS] Use ::class notation instead of string
...
Conflicts:
test/PhpParser/ParserFactoryTest.php
test/PhpParser/ParserTest.php
2018-01-13 16:08:17 +01:00
TomasVotruba
b58157f024
add strict_types to tests + fix explode type
2017-11-03 13:24:19 +01:00
TomasVotruba
af12807451
[cs] apply same to tests
2017-08-13 21:14:28 +02:00
Ekin
3c44785e82
Bump phpunit version ( #381 )
2017-04-27 18:14:07 +02:00
Nikita Popov
ceaed32e94
Fix typo in method name
2017-04-26 21:47:31 +02:00
Nikita Popov
987c61e935
Drop support for false return value in NodeTraverser
2017-02-03 22:36:57 +01:00
Nikita Popov
2b72bae3d9
Throw if NodeVisitor returns invalid value
2017-02-03 22:30:26 +01:00
Nikita Popov
2b6804aa50
Throw on nested array in NodeTraverser
...
The AST never uses deeply nested arrays, so don't support this in
the node traverser. Throw an exception instead.
2017-02-03 22:11:31 +01:00
Nikita Popov
58e7881e98
Implement NodeTraverser::STOP_TRAVERSAL
...
Conflicts:
lib/PhpParser/NodeVisitor.php
2017-01-29 22:35:40 +01:00
Nikita Popov
bcdfb703d5
Cleanup imports
...
Thanks PhpStorm :)
2016-11-23 22:58:18 +01:00
Nikita Popov
5e5cb86e83
Remove support for node cloning in traverser
2016-10-09 00:41:55 +02:00
Nikita Popov
2e5ae28c39
Don't use deprecated getMock()
2016-09-30 20:42:19 +02:00
Nikita Popov
eb4bfe1366
Add sanity check for leaveNode() return value
2016-03-27 14:52:15 +02:00
Nikita Popov
feb82eed33
Disable cloning in traverser by default
2015-07-14 17:39:56 +02:00
Matthieu Napoli
729c7bde0c
#184 Add a flag to NodeTraverser to avoid cloning nodes
2015-03-22 11:19:04 +13:00
Nikita Popov
1a627872f0
Rename nodes for compat with PHP 7
...
The old names will still be available on PHP 5.x.
2015-03-20 21:49:38 +01:00
Nikita Popov
9689763e20
Cover both DONT_TRAVERSE_CHILDREN cases
2015-01-18 00:10:01 +01:00
Nikita Popov
4071c4645d
Add NodeTraverser::DONT_TRAVERSE_CHILDREN support
2015-01-11 22:13:58 +01:00
nikic
f82862ec9c
Port library to use namespaces, with BC for old names
2014-02-06 20:29:35 +01:00