Skip to content
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

Refactor how code unit information is passed from PHPUnit #519

Open
sebastianbergmann opened this issue Apr 12, 2017 · 0 comments
Open

Refactor how code unit information is passed from PHPUnit #519

sebastianbergmann opened this issue Apr 12, 2017 · 0 comments

Comments

@sebastianbergmann
Copy link
Owner

PHPUnit turns code unit information (@covers class::method, for instance) into filename and line numbers information which this component then uses but has to convert back into code unit information when, for instance, a CoveredCodeNotExecutedException has to be raised.

It would be better for PHPUnit to pass lists of code units (from @covers and @uses annotations) to this component instead.

sebastianbergmann added a commit to sebastianbergmann/code-unit that referenced this issue Mar 1, 2020
…stead of a CodeUnit object (even if only a single CodeUnit object is to be returned)

The purpose of this component is to help with refactoring how information from @Covers and @uses annotations is passed from phpunit/phpunit to phpunit/php-code-coverage, see sebastianbergmann/php-code-coverage#519 for details.

I want this to happen sooner rather than later and do not want to wait for PHPUnit 10 and sebastianbergmann/phpunit#3631.

This means that, at least until PHPUnit 10, this component needs to support these strings for CodeUnit::fromString():

* ClassName::<public>
* ClassName::<protected>
* ClassName::<private>
* ClassName::<!public>
* ClassName::<!protected>
* ClassName::<!private>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant