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

Suggestion: sniff to check that deprecated methods are ignored for code coverage #95

Closed
jrfnl opened this issue Sep 20, 2018 · 4 comments · Fixed by #96
Closed

Suggestion: sniff to check that deprecated methods are ignored for code coverage #95

jrfnl opened this issue Sep 20, 2018 · 4 comments · Fixed by #96

Comments

@jrfnl
Copy link
Collaborator

jrfnl commented Sep 20, 2018

Related to WordPress/WordPress-Coding-Standards#993 which proposes a sniff to check various other aspects of deprecated functions/methods.

In addition to the WPCS sniff, I would like to suggest a sniff to check that any function/method which has a @deprecated tag in the Yoast plugins, also has a @codeCoverageIgnore tag.

Files which are in a deprecated folder could be ignored for this sniff (presuming that the PHPUnit code coverage configuration ignores those anyway).

Opinions ?

@IreneStr
Copy link
Contributor

Sounds like a plan. I think there is no reason for calculating coverage for deprecated functions.

@moorscode
Copy link
Contributor

That sounds great, I'm all for it!

@jrfnl
Copy link
Collaborator Author

jrfnl commented Sep 20, 2018

In that case, I may as well write it now instead of doing the manual check I was working on ;-)

@jrfnl
Copy link
Collaborator Author

jrfnl commented Sep 20, 2018

See PR #96

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants