2 <?xml-stylesheet type=
"text/css" href=
"chrome://global/skin"?>
3 <?xml-stylesheet type=
"text/css" href=
"chrome://mochikit/content/tests/SimpleTest/test.css"?>
5 https://bugzilla.mozilla.org/show_bug.cgi?id=448587.xul
7 <window title=
"Mozilla Bug 503926"
8 xmlns=
"http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
9 <script src=
"chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
11 <!-- test results are displayed in the html:body -->
12 <body xmlns=
"http://www.w3.org/1999/xhtml">
13 <a href=
"https://bugzilla.mozilla.org/show_bug.cgi?id=448587"
14 target=
"_blank">Mozilla Bug
448587</a>
17 <!-- test code goes here -->
18 <script type=
"application/javascript">
21 // Bonus test - collaborate with test_bug361111.xhtml to make sure that
22 // flushPrefEnv is appropriately called.
23 ok(!SpecialPowers.Services.prefs.prefHasUserValue('testing.some_arbitrary_pref'),
24 "Pref shouldn't carry over from previous test!");
27 /** Test for Bug
448587 **/
28 var sandbox = new Cu.Sandbox(
"about:blank");
29 var fwrapper = Cu.evalInSandbox(
"function f() {} f", sandbox);
30 is(Cu.unwaiveXrays(Cu.waiveXrays(fwrapper).prototype), Cu.evalInSandbox(
"f.prototype", sandbox),
31 ".prototype visible through .wrappedJSObject");
32 is(fwrapper.prototype, undefined,
".prototype invisible through Xrays");