-
Notifications
You must be signed in to change notification settings - Fork 30
Vale test suite #40
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
Vale test suite #40
Conversation
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.
Did you mean to commit the package-lock.json and package.json?
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.
yes, they contain the dependencies for node to be able to run the tests 👍
Adding @RayOffiah as he may have some ideas on how to make this nicer / exercise the more complicated cases within Asciidoc! Requested review from @sarahlwelton - is still a sketch really, but I think worth you playing with it at this point. |
Did a spot of work over weekend, and backed away from specifying the tests in Asciidoc - it felt like it was adding extra complication, without too many advantages. Also it's restructured, so runs (@RayOffiah if you have thoughts on doing it within Asciidoc, happy to discuss!) |
Status: Now that I don't have Asciidoc builtin, I haven't yet reinstated the pretty HTML output - working on this today. |
Now ready for review again with the directory of YAML tests and a new HTML output. |
@sarahlwelton check the styles.html to look for yourself, but here's a summary of the checks that "failed".
|
In order...
|
@sarahlwelton thanks, that's all useful context! So I think the next iterations are:
Then
|
for #40 but the action has to exist in default branch to test it 🤦
for #40 but the action has to exist in default branch to test it 🤦
link: 'https://developers.google.com/style/abbreviations' | ||
level: error | ||
scope: text | ||
# scope: text |
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.
Why did we comment out the scope
setting?
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.
oh, driveby hack hack hack hack...
and it seems not to be necessary? (At least according to the minimal test cases)
Happy to revert, but we might as well make it part of the test: can you provide a counterexample that it's needed for?
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.
If it works without it, don't worry about it - was just curious.
I can't find the documentation around the text
scope now to figure out what it's supposed to limit.
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.
Glad to see it seems to be working, here.
Gah! 😱 We now use |
Workflow: * add test/fixtures/foo.adoc * touch test/fixtures/foo.adoc.expected * npm test * npm run accept # when you're happy with the new output
Generated by Copilot, then tweaked manually where obvious what to do. There are some failures. Some things don't test properly because of the assumptions of the current test (that there is an error per line). Others I'm not yet sure how to test / why they don't work.
this will be more flexible for e.g. multiline strings than attempting to parse Asciidoc.
after much wailing and lamentation.
Please enter the commit message for your changes. Lines starting
8969b19
to
6b73cb8
Compare
Updated to integrate with main and update to add new tests. |
…rst pass on testing files to make sure compliant sentences don't violate other style rules
Workflow:
For
styles.js
For
expected.js