44 let
pb =
Cc[
"@mozilla.org/privatebrowsing;1"].
47 const EXCEPTIONS_DLG_URL =
'chrome://pippki/content/exceptionDialog.xul';
48 const EXCEPTIONS_DLG_FEATURES =
'chrome,centerscreen';
49 const INVALID_CERT_LOCATION =
'https://nocert.example.com/';
53 pb.privateBrowsingEnabled =
true;
60 exceptionAdded :
false,
61 location: INVALID_CERT_LOCATION,
62 handlePrivateBrowsing :
true,
65 function testCheckbox() {
66 let obsSvc =
Cc[
"@mozilla.org/observer-service;1"].
70 obsSvc.removeObserver(
this,
"cert-exception-ui-ready",
false);
71 ok(
win.gCert,
"The certificate information should be available now");
73 let checkbox =
win.document.getElementById(
"permanent");
74 ok(checkbox.hasAttribute(
"disabled"),
75 "the permanent checkbox should be disabled when handling the private browsing mode");
76 ok(!checkbox.hasAttribute(
"checked"),
77 "the permanent checkbox should not be checked when handling the private browsing mode");
81 },
"cert-exception-ui-ready",
false);
83 var
win = openDialog(EXCEPTIONS_DLG_URL,
"", EXCEPTIONS_DLG_FEATURES, params);
84 win.addEventListener(
"load", testCheckbox,
false);
90 exceptionAdded :
false,
91 location: INVALID_CERT_LOCATION,
94 function testCheckbox() {
95 let obsSvc =
Cc[
"@mozilla.org/observer-service;1"].
99 obsSvc.removeObserver(
this,
"cert-exception-ui-ready",
false);
100 ok(
win.gCert,
"The certificate information should be available now");
102 let checkbox =
win.document.getElementById(
"permanent");
103 ok(!checkbox.hasAttribute(
"disabled"),
104 "the permanent checkbox should not be disabled when not handling the private browsing mode");
105 ok(checkbox.hasAttribute(
"checked"),
106 "the permanent checkbox should be checked when not handling the private browsing mode");
110 },
"cert-exception-ui-ready",
false);
112 var
win = openDialog(EXCEPTIONS_DLG_URL,
"", EXCEPTIONS_DLG_FEATURES, params);
113 win.addEventListener(
"load", testCheckbox,
false);
118 pb.privateBrowsingEnabled =
false;
getService(Ci.sbIFaceplateManager)
_updateTextAndScrollDataForFrame aData
sbDeviceFirmwareAutoCheckForUpdate prototype observe