Comparing version 3.2.1 to 3.3.0
# History | ||
## 3.3.0 (2016-01-11) | ||
* Add the ability to use the `--ignore` command line more than once | ||
## 3.2.1 (2016-01-05) | ||
@@ -5,0 +9,0 @@ |
{ | ||
"name": "pa11y", | ||
"version": "3.2.1", | ||
"version": "3.3.0", | ||
@@ -5,0 +5,0 @@ "description": "pa11y is your automated accessibility testing pal", |
@@ -85,4 +85,4 @@ | ||
-l, --level <level> the level of message to fail on (exit with code 2): error, warning, notice | ||
-T, --threshold <name> the number of errors to permit before failing | ||
-i, --ignore <ignore> types and codes of messages to ignore separated by semi-colons | ||
-T, --threshold <name> the number of individual errors, warnings, or notices to permit before failing | ||
-i, --ignore <ignore> types and codes of messages to ignore, a repeatable value or separated by semi-colons | ||
-c, --config <path> a JSON config file | ||
@@ -142,2 +142,16 @@ -p, --port <port> the port to run PhantomJS on | ||
### Ignoring | ||
The ignore flag can be used in several different ways. Seperated by semi-colons: | ||
``` | ||
pa11y --ignore "warning;notice" nature.com | ||
``` | ||
or by using the flag mutiple times: | ||
``` | ||
pa11y --ignore warning --ignore notice nature.com | ||
``` | ||
### Reporters | ||
@@ -144,0 +158,0 @@ |
@@ -46,2 +46,36 @@ // This file is part of pa11y. | ||
describeCliCall('/errors', ['--ignore', 'warning', '--ignore', 'WCAG2AA.Principle3.Guideline3_1.3_1_1.H57.2'], {}, function() { | ||
it('should respond with an exit code of `0`', function() { | ||
assert.strictEqual(this.lastExitCode, 0); | ||
}); | ||
it('should respond with the expected messages', function() { | ||
assert.isArray(this.lastJsonResponse); | ||
assert.lengthEquals(this.lastJsonResponse, 1); | ||
assert.deepEqual(this.lastJsonResponse[0], { | ||
code: 'WCAG2AA.Principle2.Guideline2_4.2_4_2.H25.2', | ||
context: '<title>Page Title</title>', | ||
message: 'Check that the title element describes the document.', | ||
selector: 'html > head > title', | ||
type: 'notice', | ||
typeCode: 3 | ||
}); | ||
}); | ||
}); | ||
describeCliCall('/errors', ['--ignore', 'warning', '--ignore', 'WCAG2AA.Principle3.Guideline3_1.3_1_1.H57.2;WCAG2AA.Principle2.Guideline2_4.2_4_2.H25.2'], {}, function() { | ||
it('should respond with an exit code of `0`', function() { | ||
assert.strictEqual(this.lastExitCode, 0); | ||
}); | ||
it('should respond with the expected messages', function() { | ||
assert.isArray(this.lastJsonResponse); | ||
assert.lengthEquals(this.lastJsonResponse, 0); | ||
}); | ||
}); | ||
describeCliCall('/errors', ['--config', './mock/config/ignore.json'], {}, function() { | ||
@@ -48,0 +82,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
270418
55
2550
590