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
Add testRuleConfigs
function
#68
Conversation
This change adds a new schema property to test an invalid rule configuration.
It feels useful to test invalid configs but a little counterintuitive to do so in We created A I wonder if we can find a better home for it. Perhaps we can add another function to the preset, e.g. testInvalidRuleConfigs({
plugins: ["."],
ruleName,
configs: [
{
"config": ['foo'],
"description": "a single string" // optional description if needed
},
{
"config": [21312]
}
]
}) |
@jeddy3 Thanks for the great feedback! I agree with your suggestion, so I'll rewrite the code to create a new function. 👍🏼 |
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.
Thank you for making the changes!
It feels more intuitive as a separate function.
I've added one comment.
invalidConfig
schema propertytestRuleConfigs
function
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.
LGTM, thank you for making all the changes!
Thanks, too. I appreciate your helpful advice. 😄 I'll release the next version 6.2.0 after merging this PR! |
Ref stylelint/stylelint#7124
This change adds a new schema property to test an invalid rule configuration.Usage:This PR adds a new global function
testInvalidRuleConfigs
to test invalid rule configs.Usage:
Output: