1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/accessible/tests/mochitest/elm/test_figure.html Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,62 @@ 1.4 +<!DOCTYPE html> 1.5 +<html> 1.6 +<head> 1.7 + <title>HTML5 figure/figcaption tests</title> 1.8 + <link rel="stylesheet" type="text/css" 1.9 + href="chrome://mochikit/content/tests/SimpleTest/test.css" /> 1.10 + 1.11 + <script type="application/javascript" 1.12 + src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script> 1.13 + 1.14 + <script type="application/javascript" 1.15 + src="../common.js"></script> 1.16 + <script type="application/javascript" 1.17 + src="../role.js"></script> 1.18 + <script type="application/javascript" 1.19 + src="../attributes.js"></script> 1.20 + <script type="application/javascript" 1.21 + src="../relations.js"></script> 1.22 + <script type="application/javascript" 1.23 + src="../name.js"></script> 1.24 + 1.25 + <script type="application/javascript"> 1.26 + 1.27 + function doTest() 1.28 + { 1.29 + testRole("figure", ROLE_FIGURE); 1.30 + testRole("figcaption", ROLE_CAPTION); 1.31 + 1.32 + todo(false, "figure name gets extra whitespace in the end!"); 1.33 + testName("figure", "figure caption "); 1.34 + testName("figcaption", null); 1.35 + 1.36 + testRelation("figure", RELATION_LABELLED_BY, "figcaption"); 1.37 + testRelation("figcaption", RELATION_LABEL_FOR, "figure"); 1.38 + 1.39 + testAttrs("figure", {"xml-roles" : "figure"}, true); 1.40 + 1.41 + SimpleTest.finish(); 1.42 + } 1.43 + 1.44 + SimpleTest.waitForExplicitFinish(); 1.45 + addA11yLoadEvent(doTest); 1.46 + </script> 1.47 +</head> 1.48 +<body> 1.49 + 1.50 + <a target="_blank" 1.51 + title="Implement figure and figcaption accessibility" 1.52 + href="https://bugzilla.mozilla.org/show_bug.cgi?id=658272"> 1.53 + Mozilla Bug 658272 1.54 + </a><br/> 1.55 + <p id="display"></p> 1.56 + <div id="content" style="display: none"></div> 1.57 + <pre id="test"> 1.58 + </pre> 1.59 + 1.60 + <figure id="figure"> 1.61 + <figcaption id="figcaption">figure caption</figcaption> 1.62 + </figure> 1.63 + 1.64 +</body> 1.65 +</html>