-
Notifications
You must be signed in to change notification settings - Fork 784
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
test: require new release rule help docs to be active before creating release #1700
Conversation
test/test-rule-help-version.js
Outdated
var assert = require('assert'); | ||
var packageJSON = require(path.join(__dirname, '../package.json')); | ||
|
||
var version = packageJSON.version.substr( |
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.
This looks a little more complicated and error-prone than necessary. What about:
var [major,minor] = packageJSON.version.split('.')
var url = `https://dequeuniversity.com/rules/axe/${major}.${minor}`
// ...
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.
Also, since this test is run in a Node.js context, we can use "modern" JS syntax. We don't have PhantomJS getting in the way here.
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.
Except that our eslint blocks all es6 syntax in the test
dir.
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.
Bummer OK
92851fc
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. Nitpick, the test/*
folder allows for es6
syntax.
Per #1700 (comment), we'd need to update ESLint to allow for it. |
… release (#1700) * tests: require new release rule help docs to be active before creating release * use underscores * update comment * update comment * use split * add test_rule_help_version to workflows
This should block a release pr (a pr into
master
branch only) if the newest axe version rule help docs are not active.Reviewer checks
Required fields, to be filled out by PR reviewer(s)