-
-
Notifications
You must be signed in to change notification settings - Fork 384
Drop DOM dependency in XML Report #1125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
double check against phpstan-src@05b80ef861 on my macos m4 pro laptop before this PR (using PHPUnit 12.4.4) after this PR |
c9a346b to
b5a8841
Compare
|
Does Infection need the Of course, we would need to expose this as a configuration option. This is just an idea so far. |
great idea. I did some testing and it seems the I also did some perf testing on phpstan-src and I can see a ~15% perf improvement when I think we should tackle this in a separate PR though for this PR here to continue we need a release of the xml-tokenizer including theseer/tokenizer#38 though |
Of course. c1888bb will be released in time for PHPUnit 12.5 which uses this for sebastianbergmann/phpunit@023845a. |
|
progress on this PR is blocked on a new theseer/tokenizer release, which is blocked on a new phpunit 10.x release with fixed prefixing |
PHPUnit 10.5.60 has been released. |
|
thank you! |
49fd2ac to
ae31bc1
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1125 +/- ##
============================================
- Coverage 88.70% 88.42% -0.29%
+ Complexity 1391 1390 -1
============================================
Files 105 105
Lines 4782 4700 -82
============================================
- Hits 4242 4156 -86
- Misses 540 544 +4 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
to speedup xml report generation
|
running xml-report generation on the sebastianbergmann/php-code-coverage codebase: before this PR: after this PR: note + Generating code coverage report in PHPUnit XML format ... done [00:00.209]
- Generating code coverage report in PHPUnit XML format ... done [00:00.295] |
| </line> | ||
| </coverage> | ||
| <source> | ||
| <source xmlns="https://schema.phpunit.de/coverage/1.0"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think its not a change from a semantic point of view.
before this PR we imported one document into another which lead to the involved php extensions normalizing this namespace away. technically it is not necessary because its the same namespace as in the root phpunit element, but as this normalization no longer happens this xmlns="https://schema.phpunit.de/coverage/1.0" is showing up now.
| <token name="T_WHITESPACE"> </token> | ||
| <token name="T_OPEN_BRACKET">(</token> | ||
| <token name="T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG">&</token> | ||
| <token name="T_AMPERSAND">&</token> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure why this change happens though
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
diving into it more.. T_AMPERSAND was a token type in PHP4.x and it only existed in theseer/tokenizer, because it was hard-coded in https://github.com/theseer/tokenizer/blob/d1dd771235a40694cb5cb7239e531cf9b9702682/src/Tokenizer.php#L35
since PHP5+ the builtin token names are
T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG
and/or T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
opened a upstream discussion: theseer/tokenizer#44
requires theseer/tokenizer#38
before this PR (using PHPUnit 12.4.4)
after this PR:
env