Bug 589611 - [SeaMonkey 2.1, mochitest-browser-chrome] browser_visituri_privatebrowsing.js:64 - TypeError: Cc['@mozilla.org/privatebrowsing;1'] is undefined; (Av1) Skip this test when PB service is not available.

r=sdwilsh (a=test only).
This commit is contained in:
Serge Gautherie 2010-08-31 04:41:42 +02:00
Родитель 13db12c5b9
Коммит 6b6d3a0044
1 изменённых файлов: 8 добавлений и 1 удалений

Просмотреть файл

@ -9,7 +9,7 @@ Components.utils.import("resource://gre/modules/Services.jsm");
const INITIAL_URL = "http://example.com/tests/toolkit/components/places/tests/browser/begin.html";
const FINAL_URL = "http://example.com/tests/toolkit/components/places/tests/browser/final.html";
let gTab = gBrowser.selectedTab = gBrowser.addTab();
let gTab;
/**
* One-time observer callback.
@ -58,6 +58,13 @@ function waitForClearHistory(aCallback)
function test()
{
if (!("@mozilla.org/privatebrowsing;1" in Cc)) {
todo(false, "PB service is not available, bail out");
return;
}
gTab = gBrowser.selectedTab = gBrowser.addTab();
waitForExplicitFinish();
Services.prefs.setBoolPref("browser.privatebrowsing.keep_current_session", true);