Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | <!DOCTYPE HTML> |
michael@0 | 2 | <html> |
michael@0 | 3 | <!-- |
michael@0 | 4 | https://bugzilla.mozilla.org/show_bug.cgi?id=765993 |
michael@0 | 5 | --> |
michael@0 | 6 | <head> |
michael@0 | 7 | <title>Test for Bug 765993</title> |
michael@0 | 8 | <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script> |
michael@0 | 9 | <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/EventUtils.js"></script> |
michael@0 | 10 | <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/ChromeUtils.js"></script> |
michael@0 | 11 | <link rel="stylesheet" type="text/css" href="chrome://mochikit/content/tests/SimpleTest/test.css"/> |
michael@0 | 12 | </head> |
michael@0 | 13 | <body> |
michael@0 | 14 | <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=765993">Mozilla Bug 765993</a> |
michael@0 | 15 | <style type="text/css"> |
michael@0 | 16 | #link1 a { -moz-user-select:none; } |
michael@0 | 17 | </style> |
michael@0 | 18 | <div id="link1"><a href="http://www.mozilla.org/">link1</a></div> |
michael@0 | 19 | <div id="link2"><a href="http://www.mozilla.org/">link2</a></div> |
michael@0 | 20 | <p id="display"></p> |
michael@0 | 21 | <div id="content" style="display: none"> |
michael@0 | 22 | |
michael@0 | 23 | </div> |
michael@0 | 24 | <pre id="test"> |
michael@0 | 25 | <script type="application/javascript"> |
michael@0 | 26 | |
michael@0 | 27 | /** Test for Bug 765993 **/ |
michael@0 | 28 | |
michael@0 | 29 | Components.utils.import("resource://gre/modules/jsdebugger.jsm"); |
michael@0 | 30 | addDebuggerToGlobal(this); |
michael@0 | 31 | |
michael@0 | 32 | window.onload = function () { |
michael@0 | 33 | SimpleTest.waitForExplicitFinish(); |
michael@0 | 34 | |
michael@0 | 35 | var iframe = document.createElement("iframe"); |
michael@0 | 36 | iframe.src = "http://mochi.test:8888/tests/content/base/test/chrome/nochrome_bug765993.html"; |
michael@0 | 37 | iframe.onload = function () { |
michael@0 | 38 | var script = iframe.contentWindow.document.createElement("script"); |
michael@0 | 39 | script.src = "http://mochi.test:8888/tests/content/base/test/chrome/nochrome_bug765993.js"; |
michael@0 | 40 | script.onload = function () { |
michael@0 | 41 | var dbg = new Debugger(iframe.contentWindow); |
michael@0 | 42 | ok(dbg, "Should be able to create debugger"); |
michael@0 | 43 | |
michael@0 | 44 | var scripts = dbg.findScripts({ |
michael@0 | 45 | url: "http://mochi.test:8888/tests/content/base/test/chrome/nochrome_bug765993.js" |
michael@0 | 46 | }); |
michael@0 | 47 | ok(scripts.length > 0, "Should be able to find script"); |
michael@0 | 48 | |
michael@0 | 49 | is(scripts[0].sourceMapURL, "foo.js.map"); |
michael@0 | 50 | SimpleTest.finish(); |
michael@0 | 51 | } |
michael@0 | 52 | |
michael@0 | 53 | iframe.contentWindow.document.body.appendChild(script); |
michael@0 | 54 | }; |
michael@0 | 55 | |
michael@0 | 56 | document.body.appendChild(iframe); |
michael@0 | 57 | }; |
michael@0 | 58 | |
michael@0 | 59 | </script> |
michael@0 | 60 | </pre> |
michael@0 | 61 | </body> |
michael@0 | 62 | </html> |