-
Notifications
You must be signed in to change notification settings - Fork 671
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
getRuleName
doesn't work for packages with multiple rules.
#1054
Comments
What is it supposed to return when a package has more than one rules in it ? How does it know what to return ? |
For example, in the case of |
Or ? |
Those were just a couple of examples. What I mean is that |
Going back to my original question. What is it supposed to return when a package has more than one rules in it ? How does it know which rule name to return ? The only way to solve the problem is to take the optional rule name when calling the method ?
|
IMO, if we need to pass the rule name, then it is better to hardcode the name. Maybe you can check if getRuleName get a folder or a file, if it is a file, then you get the package name from the directory and the rule name from the fileName. |
In multi rule packages the convention so far is to name the file test the same as the rule we are testing. |
Done in 232564d. |
In these cases, it returns just the name of the package, but not the name of the rule you want to test.
The text was updated successfully, but these errors were encountered: