Adding test.
git-svn-id: svn://10.0.0.236/trunk@236419 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
cb3ab79e7b
commit
ab03af38a5
@ -48,6 +48,7 @@ _TEST_FILES = \
|
||||
test_bug159849.html \
|
||||
test_bug291377.html \
|
||||
test_bug308856.html \
|
||||
test_bug317448.html \
|
||||
test_bug333983.html \
|
||||
test_bug342448.html \
|
||||
test_bug345521.html \
|
||||
|
||||
43
mozilla/dom/tests/mochitest/bugs/test_bug317448.html
Normal file
43
mozilla/dom/tests/mochitest/bugs/test_bug317448.html
Normal file
@ -0,0 +1,43 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<!--
|
||||
https://bugzilla.mozilla.org/show_bug.cgi?id=317448
|
||||
-->
|
||||
<head>
|
||||
<title>Test for Bug 317448</title>
|
||||
<script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
|
||||
<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
||||
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
|
||||
</head>
|
||||
<body>
|
||||
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=317448">Mozilla Bug 317448</a>
|
||||
<p id="display"></p>
|
||||
<div id="content" style="display: none">
|
||||
|
||||
</div>
|
||||
<pre id="test">
|
||||
<script class="testbody" type="text/javascript">
|
||||
|
||||
/** Test for Bug 317448 **/
|
||||
var x = new XMLHttpRequest();
|
||||
x.open("GET", document.location.href);
|
||||
x.send("");
|
||||
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
||||
is(x.channel.notificationCallbacks instanceof
|
||||
Components.interfaces.nsIInterfaceRequestor,
|
||||
true, "Must be interface requestor");
|
||||
|
||||
var count = {};
|
||||
var interfaces = x.channel.notificationCallbacks.
|
||||
QueryInterface(Components.interfaces.nsIClassInfo).
|
||||
getInterfaces(count).
|
||||
map(function(id) {
|
||||
return Components.interfacesByID[id].toString();
|
||||
});
|
||||
isnot(interfaces.indexOf("nsIInterfaceRequestor"), "-1",
|
||||
"Must have interface requestor classinfo");
|
||||
</script>
|
||||
</pre>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user