fixing errors in tests 90 and 91
authorJames Craig <jcraig@apple.com>
Mon, 21 Oct 2013 19:29:20 -0700
changeset 397 42d10b65875f
parent 396 a314287caafc
child 398 4b3da7a56308
fixing errors in tests 90 and 91
ARIA-UAIG/1.0/tests/test-files/test90.html
ARIA-UAIG/1.0/tests/test-files/test91.html
--- a/ARIA-UAIG/1.0/tests/test-files/test90.html	Mon Oct 21 17:59:56 2013 -0400
+++ b/ARIA-UAIG/1.0/tests/test-files/test90.html	Mon Oct 21 19:29:20 2013 -0700
@@ -2,23 +2,26 @@
 <html>
 	<head>
 		<title>div element with role="listbox" and aria-multiselectable="true" having two child div elements with role="option" and aria-selected="true" and onload handler for page that sets aria-selected="false" on the second option</title>
-		<script type="text/javascript"><!--
-			function unselect(id = "option2") {
-                        document.getElementById(id).setAttribute("aria-selected", "false");
+		<script type="text/javascript">
+			function deselect() {
+				var elID = "option1";
+				document.getElementById(elID).setAttribute("aria-selected", "false");
 				var reporter = document.getElementById("report");
-				reporter.appendChild(reporter.ownerDocument.createTextNode("Element " + id + " has been unselected"));			}
-                  window.setTimeout(unselect, 3000);
-              --></script>
-              <style type="text/css">
-              	*[aria-selected=true] {
-              		background-color: #eee;
-              	}
-              	*[aria-selected=false] {
-              		background-color: inherit;
-              	}
-              </style>
+				reporter.innerHTML = "Element " + elID + " has been deselected";
+			}
+			window.setTimeout(deselect, 10000);
+        </script>
+		<style type="text/css">
+			*[aria-selected=true] {
+				background-color: #eee;
+			}
+			*[aria-selected=false] {
+				background-color: inherit;
+			}
+		</style>
 	</head>
 	<body>
+		<p>Selection will change after 10 seconds.</p>
 		<div id="test" role="listbox" aria-multiselectabe="true">
 			<div role="option" aria-selected="true" id="option1" tabindex="0">Option 1</div>
 			<div role="option" aria-selected="true" id="option2" tabindex="0">Option 2</div>
--- a/ARIA-UAIG/1.0/tests/test-files/test91.html	Mon Oct 21 17:59:56 2013 -0400
+++ b/ARIA-UAIG/1.0/tests/test-files/test91.html	Mon Oct 21 19:29:20 2013 -0700
@@ -2,23 +2,26 @@
 <html>
 	<head>
 		<title>div element with role="listbox" and aria-multiselectable="true" having two child div elements with role="option" and tabindex="0" and aria-selected="false" and onload handler for page that sets aria-selected="true" on the second option</title>
-		<script type="text/javascript"><!--
-			function select(id = "option2") {
-                        document.getElementById(id).setAttribute("aria-selected", "true");
+		<script type="text/javascript">
+			function selectItem() {
+				var elID = "option2";
+                document.getElementById(elID).setAttribute("aria-selected", "true");
 				var reporter = document.getElementById("report");
-				reporter.appendChild(reporter.ownerDocument.createTextNode("Element " + id + " has been selected"));			}
-                  window.setTimeout(select, 3000);
-              --></script>
-              <style type="text/css">
-              	*[aria-selected=true] {
-              		background-color: #eee;
-              	}
-              	*[aria-selected=false] {
-              		background-color: inherit;
-              	}
-              </style>
+				reporter.innerHTML = "Element " + elID + " has been selected";
+			}
+            window.setTimeout(selectItem, 10000);
+        </script>
+		<style type="text/css">
+			*[aria-selected=true] {
+				background-color: #eee;
+			}
+			*[aria-selected=false] {
+				background-color: inherit;
+			}
+		</style>
 	</head>
 	<body>
+		<p>Selection will change after 10 seconds.</p>
 		<div id="test" role="listbox" aria-multiselectabe="true">
 			<div role="option" aria-selected="false" id="option1" tabindex="0">Option 1</div>
 			<div role="option" aria-selected="false" id="option2" tabindex="0">Option 2</div>