Warning:
This wiki has been archived and is now read-only.
SC4-1-1-accesskey
From Automated WCAG Monitoring Community Group
(Redirected from SC411-accesskey)
This test belongs to 4.1.1 Parsing.
Contents
Description
This test checks accesskey attribute for all elements to have a unique value.
Background
- F17: Failure of Success Criterion 1.3.1 and 4.1.1 due to insufficient information in DOM to determine one-to-one relationships (e.g., between labels with same id) in HTML
- eGovMon test F17-1
Assumptions
- If the accesskey value has multiple characters the user agent picks the first character and ignores the rest. http://www.whatwg.org/specs/web-apps/current-work/multipage/interaction.html#the-accesskey-attribute
Test properties
| Property | Values |
|---|---|
| Test name | Provide unique accesskeys |
| Test requirement | 4.1.1 Parsing |
| Test mode | Automatic |
| Test environment | DOM |
| Test subject | single web page |
Test procedure
Selector
Test mode:
earl:automatic
Select any element with an accesskey attribute. The following CSS selector could be used: *[accesskey]
Step 1
Test mode:
earl:automatic
- IF there is no list called 'knownAccesskeys':
- Create an empty list 'knownAccesskeys;
- Take the first character of the ACCESSKEY attribute as FirstChar
- IF the FirstChar exists in 'knownAccesskeys':
- Return SC4-1-1-accesskey-fail1
- ELSE:
- Add the FirstChar to 'knownAccesskeys'
- Return SC4-1-1-accesskey-pass1
| Property | Value |
|---|---|
| TestCase | SC4-1-1-accesskey |
| Identifier | SC4-1-1-accesskey-pass1 |
| Outcome | passed |
| Pointer | selector result |
| Info |
| Property | Value |
|---|---|
| TestCase | SC4-1-1-accesskey |
| Identifier | SC4-1-1-accesskey-fail1 |
| Outcome | failed |
| ErrorMessage | The accesskey of this element has occurred before on this page |
| Pointer | selector result |
| Info |