mirror of
https://github.com/servo/servo.git
synced 2025-08-13 01:15:34 +01:00
Update web-platform-tests to revision 3bfdeb8976fc51748935c8d1f1014dfba8e08dfb
This commit is contained in:
parent
fcd6beb608
commit
cb63cfd5c7
185 changed files with 3083 additions and 1074 deletions
|
@ -0,0 +1,25 @@
|
|||
<!DOCTYPE html>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/resources/testdriver.js"></script>
|
||||
<script src="/resources/testdriver-vendor.js"></script>
|
||||
<p id="#fragment"></p>
|
||||
<script>
|
||||
promise_test(async t => {
|
||||
await test_driver.bless("request full screen", () => {
|
||||
return document.documentElement.requestFullscreen();
|
||||
});
|
||||
const fragment = document.createElement("p");
|
||||
fragment.id = "fragment";
|
||||
document.body.appendChild(fragment);
|
||||
const { type: preType } = screen.orientation;
|
||||
const isPortrait = preType.startsWith("portrait");
|
||||
const newType = `${isPortrait ? "landscape" : "portrait"}-primary`;
|
||||
const p = screen.orientation.lock(newType);
|
||||
screen.orientation.onchange = t.unreached_func(
|
||||
"change event must not fire"
|
||||
);
|
||||
window.location.href = "#fragment";
|
||||
await p;
|
||||
}, "When performing a fragment navigation, the orientation must not change or unlock");
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue