mirror of
https://github.com/lightpanda-io/browser.git
synced 2026-03-22 04:34:44 +00:00
try to make test more stable
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
function frame1Onload() {
|
function frame1Onload() {
|
||||||
window.f1_onload = true;
|
window.f1_onload = 'f1_onload_loaded';
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
@@ -11,8 +11,8 @@
|
|||||||
<iframe id=f2 src="support/sub2.html"></iframe>
|
<iframe id=f2 src="support/sub2.html"></iframe>
|
||||||
|
|
||||||
<script id="basic">
|
<script id="basic">
|
||||||
// reload it
|
// reload it
|
||||||
$('#f1').src = 'support/sub 1.html';
|
$('#f2').src = 'support/sub2.html';
|
||||||
|
|
||||||
testing.eventually(() => {
|
testing.eventually(() => {
|
||||||
testing.expectEqual(undefined, window[10]);
|
testing.expectEqual(undefined, window[10]);
|
||||||
@@ -53,7 +53,8 @@
|
|||||||
// Todo: Context security tokens
|
// Todo: Context security tokens
|
||||||
// testing.expectEqual(true, window.sub1_loaded);
|
// testing.expectEqual(true, window.sub1_loaded);
|
||||||
// testing.expectEqual(true, window.sub2_loaded);
|
// testing.expectEqual(true, window.sub2_loaded);
|
||||||
// testing.expectEqual(2, window.sub1_count);
|
// testing.expectEqual(1, window.sub1_count);
|
||||||
|
// testing.expectEqual(2, window.sub2_count);
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
@@ -68,7 +69,7 @@
|
|||||||
document.documentElement.appendChild(f3);
|
document.documentElement.appendChild(f3);
|
||||||
|
|
||||||
testing.eventually(() => {
|
testing.eventually(() => {
|
||||||
testing.expectEqual(true, window.f1_onload);
|
testing.expectEqual('f1_onload_loaded', window.f1_onload);
|
||||||
testing.expectEqual(true, f3_load_event);
|
testing.expectEqual(true, f3_load_event);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,4 +4,5 @@
|
|||||||
<script>
|
<script>
|
||||||
// should not have access to the parent's JS context
|
// should not have access to the parent's JS context
|
||||||
window.top.sub2_loaded = window.testing == undefined;
|
window.top.sub2_loaded = window.testing == undefined;
|
||||||
|
window.top.sub2_count = (window.top.sub2_count || 0) + 1;
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user