We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
IsAbstract() finds classes that are not abstract
IsAbstract()
Apparently, the bug was added on this commit
App\MyClass has 1 violations should have a name that matches Abstract* because we want to prefix abstract classes
Add the following rule:
Rule::allClasses() ->that(new IsAbstract()) ->should(new HaveNameMatching('Abstract*')) ->because('we want to prefix abstract classes');
And create a class like:
final class MyClass { }
No errors reported
The text was updated successfully, but these errors were encountered:
I have also found this to be unexpected matching and am compensating by specifically excluding everything else:
Rule::allClasses() ->that(new IsAbstract()) ->that(new IsNotInterface()) ->that(new IsNotTrait()) ->that(new IsNotFinal()) ->should(new HaveNameMatching('Abstract*')) ->because('we want to prefix abstract classes');
I'm trying to understand what problem #425 will have fixed and can't see it.
Sorry, something went wrong.
No branches or pull requests
Bug Report
Summary
IsAbstract()
finds classes that are not abstractApparently, the bug was added on this commit
Current behavior
How to reproduce
Add the following rule:
And create a class like:
Expected behavior
No errors reported
The text was updated successfully, but these errors were encountered: