Bug 1174951, test history API only after load event, r=bz

--HG--
extra : rebase_source : cc67a71af2b2296c74fc38fe97c18521d70b2093
This commit is contained in:
Olli Pettay 2015-06-24 12:13:15 -07:00
Родитель 4a89c186ce
Коммит 083507b29b
1 изменённых файлов: 10 добавлений и 3 удалений

Просмотреть файл

@ -9,7 +9,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=459470
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
<base href="http://example.org/">
</head>
<body>
<body onload="startTest();">
<a target="_blank"
href="https://bugzilla.mozilla.org/show_bug.cgi?id=459470">Mozilla Bug 459470</a><br />
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=859095">Mozilla Bug 859095</a>
@ -24,9 +24,16 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=459470
<script class="testbody" type="application/javascript;version=1.8">
SimpleTest.waitForExplicitFinish();
var gen;
gen = runTest();
gen.next();
function startTest() {
// The test uses history API, so don't do anything before load event has been
// handled.
SimpleTest.executeSoon(function() {
gen = runTest();
gen.next();
});
}
function testXMLDocURI(aDoc, aExpects) {
is(aDoc.documentURI, aExpects.documentURI, "wrong url");