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.
1 <!DOCTYPE HTML>
2 <html>
3 <!--
4 https://bugzilla.mozilla.org/show_bug.cgi?id=923010
5 -->
6 <head>
7 <meta charset="utf-8">
8 <title>Test for Bug 923010</title>
9 <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
10 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
11 <script type="application/javascript">
12 /** Test for Bug 923010 **/
13 try {
14 var conn = new mozRTCPeerConnection();
15 try {
16 conn.createAnswer(function() {
17 ok(false, "The call to createAnswer succeeded when it should have thrown");
18 }, function() {
19 ok(false, "The call to createAnswer failed when it should have thrown");
20 }, { "mandatory": { "BOGUS": 5 } } )
21 ok(false, "That call to createAnswer should have thrown");
22 } catch (e) {
23 is(e.lineNumber, 20, "Exception should have been on line 20");
24 is(e.message,
25 "createAnswer passed invalid constraints - unknown mandatory constraint: BOGUS",
26 "Should have the exception we expect");
27 }
28 } catch (e) {
29 // b2g has no WebRTC, apparently
30 todo(false, "No WebRTC on b2g yet");
31 }
32 </script>
33 </head>
34 <body>
35 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=923010">Mozilla Bug 923010</a>
36 <p id="display"></p>
37 <div id="content" style="display: none">
39 </div>
40 <pre id="test">
41 </pre>
42 </body>
43 </html>