Drop auto-run feature?
trentmwillis opened this issue · comments
So, having spent the last couple days working on the addon and trying to fix issues like #60, I am of the opinion that we should drop the "auto-run" feature for tests.
Here is my reasoning:
- It makes adoption of the addon difficult because it will likely result in many failures for existing applications.
- It can be quite spammy, since some applications trigger run-loops frequently in their app code, which amplifies point #1.
- In addition to noise, running the audit on every turn of the run-loop can also be quite slow and costly for applications with complex UIs and many test cases.
- The implementation of auto-run is hacky at best and has proven difficult to maintain, since we are effectively jamming outside, asynchronous behavior into the application's run-loop.
- The implementation is currently QUnit-specific, which limits our ability to support those using other testing libraries.
Beyond that, I see several benefits to changing the approach to be on-demand (e.g., using a11yAudit()
):
- Has a clear, incremental path for adopting accessibility testing.
- Is more explicit about when audits occur (less "magic" testing).
- It is much easier to reason about the story for passing options and scoping the audit.
- Will be much easier to maintain and test over time.
@ember-a11y/core thoughts? I'm especially curious if anyone is actually using the auto-run feature as it exists today. My hunch is that either no one is, or very few people are.
I agree with this approach.
In our use case, we turned it off app-wide, and then turn it on component by component.
Additional points from Slack:
@MelSumner: I think it aligns with how Ember (seems to be from my POV) - it would make it an easier tool to use even for those with limited exposure & supports use for those just starting out on this.
@rwjblue: I think its basically untenable to maintain the auto-run behavior with some of the things that we have planned in Ember
This has been removed in #64 and likely to be released in 0.3.0