toolkit/mozapps/extensions/test/xpinstall/bug645699.html

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

     1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     2           "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
     4 <html>
     6 <head>
     7 <title>InstallTrigger tests</title>
     8 <script type="text/javascript">
     9 function startInstall() {
    10   var whiteUrl = "https://example.org/";
    12   try {
    13     Object.defineProperty(window, "location", { value : { href : whiteUrl }	});
    14     throw new Error("Object.defineProperty(window, 'location', ...) should have thrown");
    15   } catch (exc) {
    16     if (!(exc instanceof TypeError))
    17       throw exc;
    18   }
    19   Object.defineProperty(document, "documentURIObject", { spec : { href : whiteUrl }	});
    21   InstallTrigger.install({
    22     "Unsigned XPI": "http://example.com/browser/toolkit/mozapps/extensions/test/xpinstall/unsigned.xpi"
    23   });
    24 }
    25 </script>
    26 </head>
    27 <body onload="startInstall()">
    28 <p>InstallTrigger tests</p>
    29 </body>
    30 </html>

mercurial