5 return external
.ok(b
, m
);
8 function nav_back_test() {
9 external
.trace("Running _parent navigation tests...");
11 var iframe
= document
.getElementById("testframe");
12 var subframe
= iframe
.contentWindow
.document
.createElement("iframe");
14 subframe
.onload = function() {
15 var doc
= subframe
.contentWindow
.document
;
16 doc
.body
.innerHTML
= '<a href="blank2.html" id="aid" target="_parent">test</a>';
17 doc
.getElementById("aid").click();
20 iframe
.onload = function() {
22 var href
= iframe
.contentWindow
.location
.href
;
23 ok(/.*blank2.html/.test(href
), "Unexpected href " + href
);
27 iframe
.contentWindow
.document
.body
.appendChild(subframe
);
28 subframe
.src
= "blank.html";
31 function window_navigate_test() {
32 external
.trace("Runnint window.navigate() tests...");
34 var iframe
= document
.getElementById("testframe");
36 iframe
.onload = function() {
38 var href
= iframe
.contentWindow
.location
.href
;
39 ok(href
=== "about:blank", "Unexpected href " + href
);
43 iframe
.contentWindow
.navigate("about:blank");
49 function() { external
.reportSuccess(); }
52 function next_test() {
53 window
.setTimeout(tests
.shift(), 0);
56 <body onload=
"next_test()">
57 <iframe src=
"about:blank" id=
"testframe"></iframe>