Bug 716464 - Typing about:Addons into the url bar loads the add-ons manager but doesn't hide the address bar (the test is case sensitive). r=bmcbride

This commit is contained in:
Owen Carpenter ext:(%3B%20Devan%20Sayles%20%3Cdevan.sayles%40gmail.com%3E%3B%20Joe%20Chen%20%3Cjoejoevictor%40gmail.com%3E%3B%20Jon%20Rietveld%20%3Cjonrietveld%40gmail.com%3E) 2012-01-25 17:19:14 -08:00
parent ebbc2b1777
commit 4ca07b8e14
2 changed files with 27 additions and 2 deletions

View File

@ -4793,6 +4793,7 @@ var XULBrowserWindow = {
},
hideChromeForLocation: function(aLocation) {
aLocation = aLocation.toLowerCase();
return this.inContentWhitelist.some(function(aSpec) {
return aSpec == aLocation;
});

View File

@ -104,7 +104,6 @@ function end_test() {
function test_url(aURL, aCanHide, aNextTest) {
is_chrome_visible();
info("Page load");
load_page(aURL, aCanHide, function() {
info("Switch away");
@ -163,5 +162,30 @@ function run_http_test_2() {
// Should not hide the chrome
function run_chrome_about_test_2() {
info("Chrome about: tests");
test_url("about:addons", true, end_test);
test_url("about:addons", true, run_http_test3);
}
function run_http_test3() {
info("HTTP tests");
test_url(HTTPSRC + "disablechrome.html", false, run_chrome_about_test_3);
}
// Should not hide the chrome
function run_chrome_about_test_3() {
info("Chrome about: tests");
test_url("about:Addons", true, function(){
info("Tabs on top");
TabsOnTop.enabled = true;
run_http_test4();
});
}
function run_http_test4() {
info("HTTP tests");
test_url(HTTPSRC + "disablechrome.html", false, run_chrome_about_test_4);
}
function run_chrome_about_test_4() {
info("Chrome about: tests");
test_url("about:Addons", true, end_test);
}