dequelabs / dequelabs/axe-core

Enable reviewOnFail for axe.run()

Open
#2,593 10 comments 0 reactions 0 assignees View on GitHub
core feat
Dominant language
JavaScript
Stars
7.5k
Forks
933
Avg merge
2d 23h
Merged PRs (30d)
17

Description

A `reviewOnFail` option was added in https://github.com/dequelabs/axe-core/issues/2186 This option works with `axe.configure`, but does not work with `axe.run()`.

Expectation: The `reviewOnFail` option should be honored when passed as a rule configuration to `axe.run()`

Actual: `axe.run()`does not honor/acknowledge the `reviewOnFail` option. `reviewOnFail` can only be enabled by running `axe.configure()`.

Motivation: Axe rules occasionally need to be configurable for test steps that walk through a functional workflow. A test step might disclose content with an accessibility issue that needs review. Rather than use `configure` for the rule for the entire test run it is only necessary/wanted to configure the rule for that step in the test, similar to `enable/disable`.

Requesting that axe.run() accept `reviewOnFail` as an option for rules.

```js
const options = { rules: { 'color-contrast': { reviewOnFail: true } } }; // Currently rules can only be enabled/disabled

axe.run(context, options);
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.