forked from mirrors/gecko-dev
This is split from the previous changeset since if we include dom/ the file size is too large for phabricator to handle. This is an autogenerated commit to handle scripts loading mochitest harness files, in the simple case where the script src is on the same line as the tag. This was generated with https://bug1544322.bmoattachments.org/attachment.cgi?id=9058170 using the `--part 2` argument. Differential Revision: https://phabricator.services.mozilla.com/D27457 --HG-- extra : moz-landing-system : lando
61 lines
1.4 KiB
HTML
61 lines
1.4 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>Test for Bug 1268798</title>
|
|
<script src="/tests/SimpleTest/EventUtils.js"></script>
|
|
<script src="/tests/SimpleTest/SimpleTest.js"></script>
|
|
</head>
|
|
<body>
|
|
<script>
|
|
"use strict";
|
|
|
|
function ok(condition, msg) {
|
|
opener.ok(condition, "[lenient-setters] " + msg);
|
|
}
|
|
|
|
function is(a, b, msg) {
|
|
opener.is(a, b, "[lenient-setters] " + msg);
|
|
}
|
|
|
|
function info(msg) {
|
|
opener.info("[lenient-setters] " + msg);
|
|
}
|
|
|
|
let unattachedDiv = document.createElement("div");
|
|
|
|
function begin() {
|
|
var originalValue = document.fullscreen;
|
|
try {
|
|
document.fullscreen = !document.fullscreen;
|
|
is(document.fullscreen, originalValue,
|
|
"fullscreen should not be changed");
|
|
} catch (e) {
|
|
ok(false, "Setting fullscreen should not throw");
|
|
}
|
|
|
|
var originalElem = document.fullscreenElement;
|
|
try {
|
|
document.fullscreenElement = unattachedDiv;
|
|
document.fullscreenElement = [];
|
|
is(document.fullscreenElement, originalElem,
|
|
"fullscreenElement should not be changed");
|
|
} catch (e) {
|
|
ok(false, "Setting fullscreenElement should not throw");
|
|
}
|
|
|
|
var originalEnabled = document.fullscreenEnabled;
|
|
try {
|
|
document.fullscreenEnabled = !originalEnabled;
|
|
is(document.fullscreenEnabled, originalEnabled,
|
|
"fullscreenEnabled should not be changed");
|
|
} catch (e) {
|
|
ok(false, "Setting fullscreenEnabled should not throw");
|
|
}
|
|
|
|
opener.nextTest();
|
|
}
|
|
|
|
</script>
|
|
</body>
|
|
</html>
|