Sat, 03 Jan 2015 20:18:00 +0100
Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.
michael@0 | 1 | <!DOCTYPE html> |
michael@0 | 2 | <!-- |
michael@0 | 3 | https://bugzilla.mozilla.org/show_bug.cgi?id=757771 |
michael@0 | 4 | --> |
michael@0 | 5 | <title>Test for Bug 757771</title> |
michael@0 | 6 | <script src="/tests/SimpleTest/SimpleTest.js"></script> |
michael@0 | 7 | <script src="/tests/SimpleTest/EventUtils.js"></script> |
michael@0 | 8 | <link rel="stylesheet" href="/tests/SimpleTest/test.css"> |
michael@0 | 9 | <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=757771">Mozilla Bug 757771</a> |
michael@0 | 10 | <input value=foo maxlength=4> |
michael@0 | 11 | <input type=password value=password> |
michael@0 | 12 | <script> |
michael@0 | 13 | /** Test for Bug 757771 **/ |
michael@0 | 14 | |
michael@0 | 15 | SimpleTest.waitForExplicitFinish(); |
michael@0 | 16 | SimpleTest.waitForFocus(function() { |
michael@0 | 17 | var textInput = document.querySelector("input"); |
michael@0 | 18 | textInput.focus(); |
michael@0 | 19 | textInput.select(); |
michael@0 | 20 | sendString("abcde"); |
michael@0 | 21 | |
michael@0 | 22 | var passwordInput = document.querySelector("input + input"); |
michael@0 | 23 | passwordInput.focus(); |
michael@0 | 24 | passwordInput.select(); |
michael@0 | 25 | sendString("hunter2"); |
michael@0 | 26 | |
michael@0 | 27 | ok(true, "No real tests, just crashes/asserts"); |
michael@0 | 28 | |
michael@0 | 29 | SimpleTest.finish(); |
michael@0 | 30 | }); |
michael@0 | 31 | </script> |