w3c / aria-at

Assistive Technology ARIA Experience Assessment
https://aria-at.netlify.app
Other
154 stars 28 forks source link

Initial Mode Switching Exploration #965

Closed jscholes closed 8 months ago

jscholes commented 1 year ago

Initial Mode Switching Exploration

Background

Within ARIA-AT tests targeting Windows screen readers that have multiple modes of operation (currently JAWS and NVDA), we include separate tests to evaluate behaviour in those separate modes where applicable. We have two abstract terms for these modes, "reading" and "interaction", illustrated via the following two example tests:

With default settings, both JAWS and NVDA include functionality to automatically switch between reading and interaction modes when it is felt to be appropriate, or stay in a given mode when it isn't. For example:

Most ARIA-AT tests do not currently include any assertions aimed at evaluating mode switching or retention. To my knowledge, the only test plan that does is Editor Menubar Example, which includes a single test called:

Navigate to menubar with commands that switch mode from reading to interaction

And a single relevant assertion within that test, worded as:

Change of mode from reading to interaction is conveyed

Note that this test plan has not been modified since July 29th, 2020, almost three years ago at the time of writing. As such, it does not follow many of the test writing practices established since then, such as separated tests based on directionality, test title/assertion wording, heavy reliance on setup scripts, etc.

Objective and Rationale

Mode switching and retention, herein referred to as "mode selection", are important aspects of a screen reader user's experience:

  1. Mode selection that is too frequent, not frequent enough, or otherwise not appropriate to the situation at hand can cause significant confusion and/or irritation.
  2. When a particular control requires keyboard input that would usually be intercepted for purposes of reading mode commands, the lack of automatic mode switching may result in users becoming unclear about how to operate that control.
  3. Point #2 also applies in reverse. After interacting with certain controls and then expecting to be returned to a reading context, retention of interaction mode may be disconcerting or represent a blocking issue if users do not know how to manually switch modes.

The aim, therefore, is to begin evaluating mode selection behaviour within our tests. This will represent a large scope of work, and hence our primary short-term goal is to determine:

Working Example

To aid in extrapolation of requirements, and discussion of same, this section presents a working example based on the test plan that targets the Editable Combobox with Both List and Inline Autocomplete example in the APG. The relevant test plan preview can be found at:

https://aria-at.netlify.app/review/combobox-autocomplete-both-updated.html

Note that this is not intended to be an exhaustive evaluation of how mode selection might be incorporated into an existing test plan, but rather some proposed starting points that can later be added to, subtracted from, and/or changed as needed. In particular, adaptation other test plans may end up being less or more complex than what is presented here.

Navigate to a combobox in reading mode

The title of this section represents a repeated testing task, abbreviated to remove variation between tests. Specifically, it covers the following tests:

In all cases, the included commands are:

Current Screen Reader Behaviour

With their default settings, both JAWS and NVDA behave as follows:

Questions/Comments

At a high level, there are two questions to answer for each of these outcomes:

  1. Is the current behaviour felt to be expected or not?
  2. Do we want to assert that the current behaviour should or should not be present?

Example expectations and outcomes:

Implications

Within the ARIA-AT test format, it is not currently possible to assign command-specific assertions. In this case, we cannot assert within a single test that quick navigation and arrow keys should not result in a mode switch, but Tab and Shift+Tab should.

Practically speaking, this can only be resolved by either:

  1. changing the test format and relevant tooling; or
  2. separating all relevant tests into two.
Proposed Test Separation

As a reminder, here is the list of the four relevant tests in the plan:

This could be expanded to:

This doubles the number of tests in this group, and would expand the overall test plan from 76 tests to 80 (around a 5% increase).

Potential New Tests

The previous section covered moving to/ into a combobox, but not away from/out of it. Such tests are not included right now because they wouldn't exercise screen reader functionality relating to the combobox itself.

With mode selection added to the equation, we could add new tests to assert expected behaviour when moving away from a control that requires interaction mode to be active. Here is a list of some example tests, albeit in an abbreviated form:

Note that:

Nevertheless, adding everything here on top of the test expansions from the previous section would expand the test plan from 76 to 90 tests in total, an increase of over 18%.

Modified Tests

Some existing tests in the plan could benefit from assertions being added related to mode selection. Again, these tasks are in an abbreviated form.

Other Notes

CC @IsaDC, @mcking65

jscholes commented 1 year ago

Idea: could an unexpected mode switch be listed as an unexpected behaviour?

jugglinmike commented 1 year ago

The Assistive Technology Automation Subgroup of ARIA-AT Community Group just discussed this issue. Meeting minutes are available on w3.org and also included below.

The full IRC log of that discussion <jugglinmike> Matt_King: Ultimately, what we want to come out of this with is an approach to how we're going to test mode switching with JAWS and NVDA <jugglinmike> Matt_King: One question: Are they separate tests? <jugglinmike> Matt_King: And how do we build this into the plan? <jugglinmike> James_Scholes: This is quite long and raised questions about mode switching <jugglinmike> James_Scholes: If we have a test with, say, 5 commands, and we only want to include mode switching for one command, we can't do that without expanding the test into multiple tests <jugglinmike> James_Scholes: That raises concerns about the number of tests in a plan. If we were to add every new test that I proposed (which is far from a given), we'd be growing already-large Test Plan (from 76 tests to 90 tests) <jugglinmike> James_Scholes: And that makes it even more onerous for testers <jugglinmike> James_Scholes: There are still more questions. What is the scope of the mode switching functionality that we want to test? <jugglinmike> James_Scholes: Do we want to test only that mode switching occurs when we expect it to? Or do we also want to test that an unexpected mode switch does not occur? <jugglinmike> Matt_King: We could add a mode switch to the list of "undesirable behaviors" <jugglinmike> Matt_King: That way, we wouldn't have to constantly assert that it does not happen <jugglinmike> Matt_King: But it does feel weird to have an assertion like, "the mode did not change" <jugglinmike> James_Scholes: We're testing with defaults, but we feel that having the screen reader enter interaction mode in some cases could actually be quite harmful to screen reader users because it encourages accidents <jugglinmike> Matt_King: I think if we told them to not change the mode when you press the "down arrow" key, that might be going a bit beyond the scope of ARIA-AT <jugglinmike> James_Scholes: I'm not sure that there's a significant difference between asserting that something should happen and that something should NOT happen <jugglinmike> Matt_King: I've thought of the distinction being this: if you're a web developer, and you've coded something in a particular way using ARIA, what you need is a predictable experience. I guess that kind of moves into the usability space <jugglinmike> Matt_King: If people learn that there's some reading you can do that isn't reversible... <jugglinmike> Matt_King: Well, the more I think about this, I'm not so sure. <jugglinmike> James_Scholes: For me, it doesn't feel like we're crossing any line in the tests to require that the mode must be retained <jugglinmike> James_Scholes: Let's say you manually switch to interaction mode, then you tab into this combobox, and then you leave the combobox. In that case, you remain in interaction mode <jugglinmike> James_Scholes: I think asserting against *That* behavior would be going too far <jugglinmike> Matt_King: I think that the logical next step is to explore what would be the consequences and requirements (both at the test-writing level and the system level) to be able to add those two capabilities into the Test Plans <jugglinmike> Matt_King: I made a note to myself to add an issue and put it on next week's agenda <jugglinmike> Matt_King: I think you (James_Scholes) should go ahead with exploring it on the test-writing side <= Sam_Shaw [~Sam_Shaw@7e4e2622.public.cloak] has joined #aria-at <jugglinmike> Matt_King: But the work may go beyond what we can/should manage with a single issue <jugglinmike> James_Scholes: I'll think about this, we'll talk about it, and we'll talk about it more <jugglinmike> Matt_King: It may mean the abandonment of the CSV format <jugglinmike> Matt_King: We put off developing a tool for test composition in favor of just using Excel. We may need to revisit that decision <jugglinmike> James_Scholes: Perhaps
mcking65 commented 8 months ago

@IsaDC @jscholes

Are there any unanswered questions remaining in this issue? I think we have addressed all of this with the V2 format and we could close this issue? Do you concur?

IsaDC commented 8 months ago

@IsaDC @jscholes

Are there any unanswered questions remaining in this issue? I think we have addressed all of this with the V2 format and we could close this issue? Do you concur?

Agree. We can close this issue.

jscholes commented 8 months ago

Yep, closing.