security/manager/ssl/tests/mochitest/mixedcontent/test_cssContent2.html

Wed, 31 Dec 2014 07:16:47 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 07:16:47 +0100
branch
TOR_BUG_9701
changeset 3
141e0f1194b1
permissions
-rw-r--r--

Revert simplistic fix pending revisit of Mozilla integration attempt.

     1 <!DOCTYPE HTML>
     2 <html>
     3 <head>
     4   <title>CSS conent styling 2</title>
     5   <script type="text/javascript" src="/MochiKit/Base.js"></script>
     6   <script type="text/javascript" src="/MochiKit/DOM.js"></script>
     7   <script type="text/javascript" src="/MochiKit/Style.js"></script>
     8   <script type="text/javascript" src="/MochiKit/Signal.js"></script>
     9   <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
    10   <script type="text/javascript" src="mixedContentTest.js"></script>
    11   <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
    13   <script class="testbody" type="text/javascript">
    15   if (navigator.platform.startsWith("Mac")) {
    16     SimpleTest.expectAssertions(0, 1);
    17   }
    19   function runTest()
    20   {
    21     isSecurityState("secure");
    22     document.getElementById("para").style.content =
    23       "url('http://example.com/tests/security/manager/ssl/tests/mochitest/mixedcontent/moonsurface.jpg')";
    25     waitForSecurityState("broken", function()
    26     {
    27       isSecurityState("broken", "insecure content added by styling breaks security");
    28       finish();
    29     });
    30   }
    32   function afterNavigationTest()
    33   {
    34     is(document.getElementById("para").style.content, "");
    35     isSecurityState("secure", "security full after navigation");
    36     finish();
    37   }
    39   </script>
    40 </head>
    42 <body>
    43   <p id="para"></p>
    44 </body>
    45 </html>

mercurial