3 if (window
.testRunner
) {
4 testRunner
.dumpAsText();
5 testRunner
.waitUntilDone();
9 document
.write("<div>Should be 12:</div><div>1");
11 if (document
.getElementsByTagName("div").length
!= 2)
12 alert("Error - wrong number of DIVs at step 1");
14 if (document
.getElementsByTagName("div")[1].textContent
!= "1")
15 alert("Error - incorrect div content at step 1");
17 setTimeout(test2
, 10);
21 document
.write("2</div>")
23 if (document
.getElementsByTagName("div").length
!= 2)
24 alert("Error - wrong number of DIVs at step 2");
26 if (document
.getElementsByTagName("div")[1].textContent
!= "12")
27 alert("Error - incorrect div content at step 2");
31 setTimeout("testRunner.notifyDone()", 10);
35 <body onload=
"test()">