gecko/dom/alarm/test/test_alarm_non_permitted_app.html

33 lines
821 B
HTML

<!DOCTYPE HTML>
<html>
<head>
<title>Test Non-Permitted Application for Alarm API</title>
<script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
</head>
<body>
<p id="display"></p>
<div id="content" style="display: none"></div>
<pre id="test">
<script type="application/javascript">
"use strict";
SimpleTest.waitForExplicitFinish();
SpecialPowers.pushPrefEnv({"set": [["dom.mozAlarms.enabled", true]]}, function() {
SpecialPowers.removePermission("alarms", document);
var mozAlarms = navigator.mozAlarms;
ok('mozAlarms' in navigator, "navigator.mozAlarms should exist");
is(mozAlarms, null, "navigator.mozAlarms should return null");
SimpleTest.finish();
});
</script>
</pre>
</body>
</html>