Warning:
This wiki has been archived and is now read-only.

SC2-4-2-titles-across-pages

From Automated WCAG Monitoring Community Group
Jump to: navigation, search

This test is a part of 2.4.2 Page Titled

Status

Version 0: For review

Description

This test checks that webpage titles are used to uniquely identify individual webpages within a website.

Assumptions

  • All pages tested should be on the same website (with same domain). Page titles on external websites are out of the scope of the test.
  • The test does not include pages that are the result of a user interaction (such as pages that represent steps in a check out process on a retail website), or pages that require a login. These pages can be tested individually using SC2-4-2-title.
  • The case of missing or invalid or titles of individual webpages is covered in test SC2-4-2-title. This test does not duplicate these checks.
  • If no pages with same domain are linked from the page where the test is run, the test automatically passes (for best results, run this test from the front page or main page of the website).
  • If every page in the sample has identical titles, the test automatically fails.
  • If one or more group of pages within the website have identical titles, users are asked to evaluate each group.

Background

Test properties

Property Possible values
Test name Titles Across Pages
Test requirement 2.4.2 Page Titled
Test mode Semiauto
Required expertise and skills no prior knowledge
Additional expertise and skills
Test environment HTML source or DOM
Test subject multiple web pages

Test procedure

 

Selector

Test mode: earl:automatic


Extract the <title> element from the <head> section of all pages in the collection. To create a page collection, follow all links from the page currently being tested, include all pages on same domain. Exclude all pages with no title elements or multiple title elements (they are covered in a different test).  

Step 1

Test mode: earl:automatic

If one or more pages is returned, and all titles are unique: return

Property Value
TestCase SC2-4-2-titles-across-pages
Identifier SC2-4-2-titles-across-pages-pass1
Outcome passed
Pointer position
Info


else If more than one page is returned, and all pages in the set have identical titles.

return

Property Value
TestCase SC2-4-2-titles-across-pages
Identifier SC2-4-2-titles-across-pages-fail1
Outcome failed
ErrorMessage All page titles are identical.
Pointer position
Info


Else, continue with Step 2

Step 2

Test mode: earl:manual

Create lists of pages with identical page titles. For each title value that is used on more than one page create a nested list of all the URLs where that title is used. For instance:

  • Title 1
    • URL 1 for title 1
    • URL 2 for title 1
    • ... URL N for title 1
  • title 2
    • URL 1 for title 2.
    • ... URL N for title 2.

For each title with more than one URL associated with it: Present the page title to the user along with a list of the URLs where it is used. Ask the usre to open at least two of those URLs in a separate window or tab and inspect the content of those pages.  

User input question

Item presented to the user: A list of URLs (to webpages with identical titles).

Question: Please activate at least two of the following URLs and take a look at the webpages. Does the webpage title accurately describe the purpose or content of all of these webpages?

Answer options: "yes/no"

Help text: A page title should uniquely identify the webpage within a website. Occasionally webpages may be so similar as to justify having the same title, e.g. title="Product FAQ" for product FAQ webpages (as long as the main heading of that page uniquely identifies the product). But more often than not it means that a generic title, perhaps created from a template is being used without consideration of the page context.

Repair suggestion: none

Properties of the test step:

  • context-sensitive = yes
  • user interaction (with the web content) required = yes


If no return

Property Value
TestCase SC2-4-2-titles-across-pages
Identifier SC2-4-2-titles-across-pages-fail2
Outcome failed
ErrorMessage Page titles need to be unique and descriptive, at least x pages on your website have identical titles. (where x is the number of pages with identical titles)
Pointer position
Info


else 

return

Property Value
TestCase SC2-4-2-titles-across-pages
Identifier SC2-4-2-titles-across-pages-pass2
Outcome passed
Pointer position
Info