mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-04 13:07:52 +00:00
Bug 799229 - Move the ForgetAboutSite modules to toolkit; r=Mossop
--HG-- rename : browser/components/privatebrowsing/src/ForgetAboutSite.jsm => toolkit/forgetaboutsite/ForgetAboutSite.jsm rename : browser/components/privatebrowsing/test/browser/browser_privatebrowsing_clearplugindata.html => toolkit/forgetaboutsite/test/browser/browser_clearplugindata.html rename : browser/components/privatebrowsing/test/browser/browser_privatebrowsing_clearplugindata.js => toolkit/forgetaboutsite/test/browser/browser_clearplugindata.js rename : browser/components/privatebrowsing/test/unit/downloads.empty.sqlite => toolkit/forgetaboutsite/test/unit/downloads.empty.sqlite rename : browser/components/privatebrowsing/test/unit/test_removeDataFromDomain.js => toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain.js rename : browser/components/privatebrowsing/test/unit/test_removeDataFromDomain_activeDownloads.js => toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain_activeDownloads.js
This commit is contained in:
parent
4841edf196
commit
b9a98507da
@ -29,8 +29,4 @@ EXTRA_PP_COMPONENTS = \
|
||||
nsPrivateBrowsingService.js \
|
||||
$(NULL)
|
||||
|
||||
EXTRA_JS_MODULES = \
|
||||
ForgetAboutSite.jsm \
|
||||
$(NULL)
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
@ -14,8 +14,6 @@ MOCHITEST_BROWSER_FILES = \
|
||||
head.js \
|
||||
browser_console_clear.js \
|
||||
browser_privatebrowsing_certexceptionsui.js \
|
||||
browser_privatebrowsing_clearplugindata.js \
|
||||
browser_privatebrowsing_clearplugindata.html \
|
||||
browser_privatebrowsing_commandline_toggle.js \
|
||||
browser_privatebrowsing_concurrent.js \
|
||||
browser_privatebrowsing_concurrent_page.html \
|
||||
|
@ -13,8 +13,6 @@ const kPrivateBrowsingTransitionCompleteNotification = "private-browsing-transit
|
||||
const kEnter = "enter";
|
||||
const kExit = "exit";
|
||||
|
||||
const NS_APP_USER_PROFILE_50_DIR = "ProfD";
|
||||
|
||||
function LOG(aMsg) {
|
||||
aMsg = ("*** PRIVATEBROWSING TESTS: " + aMsg);
|
||||
Cc["@mozilla.org/consoleservice;1"].getService(Ci.nsIConsoleService).
|
||||
|
@ -17,6 +17,4 @@ tail = tail_privatebrowsing.js
|
||||
[test_privatebrowsingwrapper_exit.js]
|
||||
[test_privatebrowsingwrapper_placesTitleNoUpdate.js]
|
||||
[test_privatebrowsingwrapper_telemetry.js]
|
||||
[test_removeDataFromDomain.js]
|
||||
[test_removeDataFromDomain_activeDownloads.js]
|
||||
[test_transition_nooffline.js]
|
||||
|
@ -51,6 +51,7 @@ skip-if = os == "android"
|
||||
[include:toolkit/components/telemetry/tests/unit/xpcshell.ini]
|
||||
[include:toolkit/components/social/test/xpcshell/xpcshell.ini]
|
||||
[include:toolkit/components/mediasniffer/test/unit/xpcshell.ini]
|
||||
[include:toolkit/forgetaboutsite/test/unit/xpcshell.ini]
|
||||
[include:toolkit/content/tests/unit/xpcshell.ini]
|
||||
[include:toolkit/identity/tests/unit/xpcshell.ini]
|
||||
[include:toolkit/mozapps/downloads/tests/unit/xpcshell.ini]
|
||||
|
@ -14,6 +14,7 @@ PARALLEL_DIRS = \
|
||||
components \
|
||||
content \
|
||||
devtools \
|
||||
forgetaboutsite \
|
||||
identity \
|
||||
locales \
|
||||
mozapps/downloads \
|
||||
|
20
toolkit/forgetaboutsite/Makefile.in
Normal file
20
toolkit/forgetaboutsite/Makefile.in
Normal file
@ -0,0 +1,20 @@
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
DEPTH := @DEPTH@
|
||||
topsrcdir := @top_srcdir@
|
||||
srcdir := @srcdir@
|
||||
VPATH := @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
MODULE := forgetaboutsite
|
||||
|
||||
EXTRA_JS_MODULES := \
|
||||
ForgetAboutSite.jsm \
|
||||
$(NULL)
|
||||
|
||||
TEST_DIRS := test
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
18
toolkit/forgetaboutsite/test/Makefile.in
Normal file
18
toolkit/forgetaboutsite/test/Makefile.in
Normal file
@ -0,0 +1,18 @@
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
DEPTH := @DEPTH@
|
||||
topsrcdir := @top_srcdir@
|
||||
srcdir := @srcdir@
|
||||
VPATH := @srcdir@
|
||||
relativesrcdir := @relativesrcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
MODULE := forgetaboutsite
|
||||
|
||||
DIRS := browser
|
||||
XPCSHELL_TESTS := unit
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
19
toolkit/forgetaboutsite/test/browser/Makefile.in
Normal file
19
toolkit/forgetaboutsite/test/browser/Makefile.in
Normal file
@ -0,0 +1,19 @@
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
DEPTH := @DEPTH@
|
||||
topsrcdir := @top_srcdir@
|
||||
srcdir := @srcdir@
|
||||
VPATH := @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
MODULE := forgetaboutsite
|
||||
|
||||
MOCHITEST_BROWSER_FILES := \
|
||||
browser_clearplugindata.js \
|
||||
browser_clearplugindata.html \
|
||||
$(NULL)
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
@ -5,8 +5,8 @@
|
||||
|
||||
Components.utils.import("resource://gre/modules/ForgetAboutSite.jsm");
|
||||
|
||||
// Test clearing plugin data by domain using nsPrivateBrowsingService.
|
||||
const testURL = "http://mochi.test:8888/browser/browser/components/privatebrowsing/test/browser/browser_privatebrowsing_clearplugindata.html";
|
||||
// Test clearing plugin data by domain using ForgetAboutSite.
|
||||
const testURL = "http://mochi.test:8888/browser/toolkit/forgetaboutsite/test/browser/browser_clearplugindata.html";
|
||||
|
||||
const pluginHostIface = Ci.nsIPluginHost;
|
||||
var pluginHost = Cc["@mozilla.org/plugin/host;1"].getService(Ci.nsIPluginHost);
|
32
toolkit/forgetaboutsite/test/unit/head_forgetaboutsite.js
Normal file
32
toolkit/forgetaboutsite/test/unit/head_forgetaboutsite.js
Normal file
@ -0,0 +1,32 @@
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
const Cc = Components.classes;
|
||||
const Ci = Components.interfaces;
|
||||
const Cu = Components.utils;
|
||||
|
||||
var dirSvc = Cc["@mozilla.org/file/directory_service;1"].getService(Ci.nsIProperties);
|
||||
var profileDir = do_get_profile();
|
||||
|
||||
/**
|
||||
* Removes any files that could make our tests fail.
|
||||
*/
|
||||
function cleanUp()
|
||||
{
|
||||
let files = [
|
||||
"downloads.sqlite",
|
||||
"places.sqlite",
|
||||
"cookies.sqlite",
|
||||
"signons.sqlite",
|
||||
"permissions.sqlite"
|
||||
];
|
||||
|
||||
for (let i = 0; i < files.length; i++) {
|
||||
let file = dirSvc.get("ProfD", Ci.nsIFile);
|
||||
file.append(files[i]);
|
||||
if (file.exists())
|
||||
file.remove(false);
|
||||
}
|
||||
}
|
||||
cleanUp();
|
6
toolkit/forgetaboutsite/test/unit/xpcshell.ini
Normal file
6
toolkit/forgetaboutsite/test/unit/xpcshell.ini
Normal file
@ -0,0 +1,6 @@
|
||||
[DEFAULT]
|
||||
head = head_forgetaboutsite.js
|
||||
tail =
|
||||
|
||||
[test_removeDataFromDomain.js]
|
||||
[test_removeDataFromDomain_activeDownloads.js]
|
@ -485,6 +485,9 @@ MAKEFILES_xulapp="
|
||||
toolkit/components/viewsource/Makefile
|
||||
toolkit/devtools/Makefile
|
||||
toolkit/devtools/sourcemap/Makefile
|
||||
toolkit/forgetaboutsite/Makefile
|
||||
toolkit/forgetaboutsite/test/Makefile
|
||||
toolkit/forgetaboutsite/test/browser/Makefile
|
||||
toolkit/identity/Makefile
|
||||
toolkit/locales/Makefile
|
||||
toolkit/mozapps/downloads/Makefile
|
||||
|
Loading…
x
Reference in New Issue
Block a user