1. Introduction
The term Input Aspects is defined by the Accessibility Conformance Testing (ACT) Rules Format 1.0 Specification. An input aspect is a distinct part of a test subject. Atomic rules are required to list input aspects in the applicability and expectations.
Some input aspects are already well defined in a formal specification within the context of web content, such as HTTP messages, DOM tree, and CSS Styling. These do not warrant a detailed description in ACT Rules Format 1.0 specification. Instead, these are listed in this informative document, which can be updated more easily. Atomic rules can refer to one of these common input aspects, however, these common input aspects are not required to conform to the ACT Rules Format 1.0 specification.
Examples of ACT Rules can be found in the ACT Rules Repository.
The input aspects listed in this document can be used by authors of ACT Rules to refer to common types more easily. This improves the development process and supports consistency across rules. This list can be extended and refined at any time, for example, to include popular input aspects or to provide clarification. Existing input aspects can also be marked as obsoleted, if needed.
2. Common Input Aspects
2.1. HTTP Messages
The HTTP messages [http11] exchanged between a client and a server as part of requesting a web page may be of interest to ACT Rules. For example, analyzing HTTP messages to perform validation of HTTP headers or unparsed HTML [HTML] and Cascading Style Sheets.
2.2. DOM Tree
The DOM [DOM] tree constructed from parsing HTML [HTML], and optionally executing DOM manipulating JavaScript, may be of interest to ACT Rules to test the structure of web pages. In the DOM tree, information about individual elements of a web page, and their relations, becomes available.
The means by which the DOM tree is constructed, be it by a web browser or not, is not of importance as long as the construction follows the Document Object Model [DOM].
2.3. CSS Styling
The computed CSS Styling resulting from parsing CSS and applying it to the DOM [DOM] may be of interest to ACT Rules that wish to test the web page as presented to the user. Through CSS styling, information about the position, the foreground and background colors, the visibility, and more, of elements becomes available.
The means by which the CSS styling is computed, be it by a web browser or not, is not of importance as long as the computation follows any applicable specifications that might exist, such as the CSS Object Model [CSSOM].
The test cases of ACT Rules interested in the CSS styling must be viewed with the CSS included by the author, and the user agent default style sheet. User style sheets and other custom styles should be avoided to ensure test cases have the expected outcome.
2.4. Accessibility Tree
The accessibility tree constructed from extracting information from both the DOM [DOM] tree and the CSS Styling may be of interest to ACT Rules. This can be used to test the web page as presented to assistive technologies such as screen readers. Through the accessibility tree, information about the semantic roles, accessible names and descriptions, and more, of elements becomes available.
The means by which the accessibility tree is constructed, be it by a web browser or not, is not of importance as long as the construction follows any applicable specifications that might exist, such as the Core Accessibility API Mappings 1.1 [CORE-AAM-1.1].
2.5. Language
Language, either written or spoken, contained in nodes of the DOM [DOM] or accessibility trees may be of interest to ACT Rules that intend to test things like complexity or intention of the language. For example, an ACT Rule might test that paragraphs of text within the DOM tree do not exceed a certain readability score or that the text alternative of an image provides a sufficient description.
Rules can only operate on the Language aspect if the language of a page can be determined. The means by which the language is assessed, whether by a person or a machine, is not of importance as long as the assessment meets the criteria defined in Requirements for WCAG 2.0 Checklists and Techniques § humantestable [WCAG].
Some rules can only operate on a Language aspect if the language is sufficiently understood by the tester, while other rules only require identifying the language. For example, a rule checking that an accessible name is descriptive can only function if the language is understood. A rule checking the correctness of a lang
attribute requires knowing what language is used, but not the meaning of the words.
2.6. Source Code
The text content of a file from which a web browser or other user agent creates a page. For example, a browser may build up a web page from an HTML file, CSS file, SVG file and JavaScript file. The text of each of these four files is its source code. An ACT Rule could for example test for potential parser errors.
Source code is distinct from an HTTP response, which includes HTTP headers. It is the text content of the file before parsing, which often results in an object model or syntax tree, or serialized versions of those. Notably in HTML, the outerHTML property of the root node can vary significantly from its source code. For the purpose of ACT rules, source files processed on the server such as PHP for creating HTML, or SASS for creating CSS are not considered, as those are not processed by the user agent.
2.7. Audio Output
Audio output may be of interest to ACT Rules that intend to test things like the speech and sounds provided in media files. Some rules can operate on whether there is audio output, such as an ACT Rule that may check that audio output on a Web page does not play automatically. Some rules can only operate if the audio output is understood by the tester. For example, a rule checking that captions are equivalent can only function if the audio output is understood.
2.8. Visual Output
Visual output may be of interest to ACT Rules that intend to test things like the moving images displayed in media or animation files. Some rules can operate on the presence of visual output, such as an ACT Rule that may check that visual output has a control to stop it. Some rules can only operate if the visual output is understood by the tester. For example, a rule checking that the visual output information is available in a transcript.