mirror of
https://github.com/servo/servo.git
synced 2025-08-07 22:45:34 +01:00
parent
839b7fe8ef
commit
cb47a7e403
15 changed files with 156 additions and 0 deletions
|
@ -8408,6 +8408,18 @@
|
|||
"url": "/_mozilla/mozilla/global.html"
|
||||
}
|
||||
],
|
||||
"mozilla/globals/entry.html": [
|
||||
{
|
||||
"path": "mozilla/globals/entry.html",
|
||||
"url": "/_mozilla/mozilla/globals/entry.html"
|
||||
}
|
||||
],
|
||||
"mozilla/globals/entry.worker.js": [
|
||||
{
|
||||
"path": "mozilla/globals/entry.worker.js",
|
||||
"url": "/_mozilla/mozilla/globals/entry.worker.html"
|
||||
}
|
||||
],
|
||||
"mozilla/hit_test_nested_sc.html": [
|
||||
{
|
||||
"path": "mozilla/hit_test_nested_sc.html",
|
||||
|
|
3
tests/wpt/mozilla/meta/mozilla/globals/entry.html.ini
Normal file
3
tests/wpt/mozilla/meta/mozilla/globals/entry.html.ini
Normal file
|
@ -0,0 +1,3 @@
|
|||
[entry.html]
|
||||
type: testharness
|
||||
prefs: [dom.testbinding.enabled:true]
|
|
@ -0,0 +1,3 @@
|
|||
[entry.worker.html]
|
||||
type: testharness
|
||||
prefs: [dom.testbinding.enabled:true]
|
2
tests/wpt/mozilla/tests/mozilla/globals/empty.html
Normal file
2
tests/wpt/mozilla/tests/mozilla/globals/empty.html
Normal file
|
@ -0,0 +1,2 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Empty page</title>
|
16
tests/wpt/mozilla/tests/mozilla/globals/entry.html
Normal file
16
tests/wpt/mozilla/tests/mozilla/globals/entry.html
Normal file
|
@ -0,0 +1,16 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>Entry page</title>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script>
|
||||
var entry_test = async_test("Entry global");
|
||||
var loaded = function() {
|
||||
entry_test.step(function() {
|
||||
var entry = document.querySelector("#incumbent").contentWindow.get_entry();
|
||||
assert_equals(entry, window);
|
||||
});
|
||||
entry_test.done();
|
||||
}
|
||||
</script>
|
||||
<iframe id="incumbent" src="incumbent.html" onload="loaded()"></iframe>
|
9
tests/wpt/mozilla/tests/mozilla/globals/entry.worker.js
Normal file
9
tests/wpt/mozilla/tests/mozilla/globals/entry.worker.js
Normal file
|
@ -0,0 +1,9 @@
|
|||
importScripts("/resources/testharness.js");
|
||||
|
||||
test(function() {
|
||||
var entry = (new TestBinding()).entryGlobal();
|
||||
assert_equals(entry, self);
|
||||
});
|
||||
|
||||
|
||||
done();
|
13
tests/wpt/mozilla/tests/mozilla/globals/incumbent.html
Normal file
13
tests/wpt/mozilla/tests/mozilla/globals/incumbent.html
Normal file
|
@ -0,0 +1,13 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Incumbent page</title>
|
||||
|
||||
<iframe src="empty.html" id="current"></iframe>
|
||||
<iframe src="empty.html" id="relevant"></iframe>
|
||||
<script>
|
||||
function get_entry() {
|
||||
var current = document.querySelector("#current").contentWindow;
|
||||
var relevant = document.querySelector("#relevant").contentWindow;
|
||||
|
||||
return current.TestBinding.prototype.entryGlobal.call(new relevant.TestBinding());
|
||||
}
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue