зеркало из https://github.com/mozilla/pjs.git
Bug 728626 - Non-Firefox tests should not use 'about:robots' which is Firefox specific. r=ttaubert
This commit is contained in:
Родитель
57155591da
Коммит
35e2050b31
|
@ -102,7 +102,7 @@ var gTestSteps = [
|
|||
ensure_opentabs_match_db(nextStep);
|
||||
});
|
||||
}, true);
|
||||
tab.linkedBrowser.loadURI('about:robots');
|
||||
tab.linkedBrowser.loadURI("about:mozilla");
|
||||
},
|
||||
function() {
|
||||
info("Running step 9 - enter private browsing mode, without keeping session");
|
||||
|
|
|
@ -15,7 +15,7 @@ function test() {
|
|||
is(gBrowser.visibleTabs.length, 2, "2 tabs should be open");
|
||||
is(Disabled(), true, "Bookmark All Tabs should be disabled since there are two tabs with the same address");
|
||||
|
||||
let testTab2 = gBrowser.addTab("about:robots");
|
||||
let testTab2 = gBrowser.addTab("about:mozilla");
|
||||
is(gBrowser.visibleTabs.length, 3, "3 tabs should be open");
|
||||
// Wait for tab load, the code checks for currentURI.
|
||||
testTab2.linkedBrowser.addEventListener("load", function () {
|
||||
|
|
|
@ -4,6 +4,6 @@
|
|||
</head>
|
||||
<frameset cols="*,*">
|
||||
<frame name="left" src="frameLeft.html">
|
||||
<frame name="right" src="about:robots">
|
||||
<frame name="right" src="about:mozilla">
|
||||
</frameset>
|
||||
</html>
|
||||
|
|
|
@ -20,30 +20,30 @@ function test() {
|
|||
waitForExplicitFinish();
|
||||
|
||||
let aboutBrowser = gBrowser.getBrowserForTab(tabAbout);
|
||||
aboutBrowser.addEventListener("load", function () {
|
||||
aboutBrowser.removeEventListener("load", arguments.callee, true);
|
||||
let tabRobots = gBrowser.addTab();
|
||||
gBrowser.selectedTab = tabRobots;
|
||||
aboutBrowser.addEventListener("load", function onAboutBrowserLoad() {
|
||||
aboutBrowser.removeEventListener("load", onAboutBrowserLoad, true);
|
||||
let tabMozilla = gBrowser.addTab();
|
||||
gBrowser.selectedTab = tabMozilla;
|
||||
|
||||
let robotsBrowser = gBrowser.getBrowserForTab(tabRobots);
|
||||
robotsBrowser.addEventListener("load", function () {
|
||||
robotsBrowser.removeEventListener("load", arguments.callee, true);
|
||||
let robotsZoom = ZoomManager.zoom;
|
||||
let mozillaBrowser = gBrowser.getBrowserForTab(tabMozilla);
|
||||
mozillaBrowser.addEventListener("load", function onMozillaBrowserLoad() {
|
||||
mozillaBrowser.removeEventListener("load", onMozillaBrowserLoad, true);
|
||||
let mozillaZoom = ZoomManager.zoom;
|
||||
|
||||
// change the zoom on the robots page
|
||||
// change the zoom on the mozilla page
|
||||
FullZoom.enlarge();
|
||||
// make sure the zoom level has been changed
|
||||
isnot(ZoomManager.zoom, robotsZoom, "Zoom level can be changed");
|
||||
robotsZoom = ZoomManager.zoom;
|
||||
isnot(ZoomManager.zoom, mozillaZoom, "Zoom level can be changed");
|
||||
mozillaZoom = ZoomManager.zoom;
|
||||
|
||||
// switch to about: tab
|
||||
gBrowser.selectedTab = tabAbout;
|
||||
|
||||
// switch back to robots tab
|
||||
gBrowser.selectedTab = tabRobots;
|
||||
// switch back to mozilla tab
|
||||
gBrowser.selectedTab = tabMozilla;
|
||||
|
||||
// make sure the zoom level has not changed
|
||||
is(ZoomManager.zoom, robotsZoom,
|
||||
is(ZoomManager.zoom, mozillaZoom,
|
||||
"Entering private browsing should not reset the zoom on a tab");
|
||||
|
||||
// leave private browsing mode
|
||||
|
@ -52,11 +52,11 @@ function test() {
|
|||
// cleanup
|
||||
gPrefService.clearUserPref("browser.privatebrowsing.keep_current_session");
|
||||
FullZoom.reset();
|
||||
gBrowser.removeTab(tabRobots);
|
||||
gBrowser.removeTab(tabMozilla);
|
||||
gBrowser.removeTab(tabAbout);
|
||||
finish();
|
||||
}, true);
|
||||
robotsBrowser.contentWindow.location = "about:robots";
|
||||
mozillaBrowser.contentWindow.location = "about:mozilla";
|
||||
}, true);
|
||||
aboutBrowser.contentWindow.location = "about:";
|
||||
}
|
||||
|
|
|
@ -24,10 +24,10 @@ function onTabViewWindowLoaded() {
|
|||
contentWindow = document.getElementById("tab-view").contentWindow;
|
||||
|
||||
originalTab = gBrowser.selectedTab;
|
||||
newTabs = [gBrowser.addTab("about:robots"), gBrowser.addTab("about:mozilla"), gBrowser.addTab("about:license")];
|
||||
newTabs = [gBrowser.addTab("about:rights"), gBrowser.addTab("about:mozilla"), gBrowser.addTab("about:license")];
|
||||
|
||||
is(originalTab._tPos, 0, "Original tab is in position 0");
|
||||
is(newTabs[0]._tPos, 1, "Robots is in position 1");
|
||||
is(newTabs[0]._tPos, 1, "Rights is in position 1");
|
||||
is(newTabs[1]._tPos, 2, "Mozilla is in position 2");
|
||||
is(newTabs[2]._tPos, 3, "License is in position 3");
|
||||
|
||||
|
@ -51,7 +51,7 @@ function onTabViewWindowHidden() {
|
|||
|
||||
is(newTabs[2]._tPos, 0, "License is in position 0");
|
||||
is(originalTab._tPos, 1, "Original tab is in position 1");
|
||||
is(newTabs[0]._tPos, 2, "Robots is in position 2");
|
||||
is(newTabs[0]._tPos, 2, "Rights is in position 2");
|
||||
is(newTabs[1]._tPos, 3, "Mozilla is in position 3");
|
||||
|
||||
gBrowser.removeTab(newTabs[0]);
|
||||
|
|
|
@ -40,7 +40,7 @@ function test3() {
|
|||
whenTabViewIsHidden(function() {
|
||||
is(gBrowser.tabs.length, 2, "There are two tabs after cmd/ctrl + t is pressed");
|
||||
|
||||
gBrowser.tabs[0].linkedBrowser.loadURI("about:robots");
|
||||
gBrowser.tabs[0].linkedBrowser.loadURI("about:mozilla");
|
||||
gBrowser.tabs[1].linkedBrowser.loadURI("http://example.com/");
|
||||
|
||||
afterAllTabsLoaded(function () {
|
||||
|
|
|
@ -29,7 +29,7 @@ function onTabViewWindowLoaded(win) {
|
|||
let datatext = win.gBrowser.loadOneTab("data:text/plain,bug610242", bg);
|
||||
let datahtml = win.gBrowser.loadOneTab("data:text/html,<blink>don't blink!</blink>", bg);
|
||||
let mozilla = win.gBrowser.loadOneTab("about:mozilla", bg);
|
||||
let robots = win.gBrowser.loadOneTab("about:robots", bg);
|
||||
let synclog = win.gBrowser.loadOneTab("about:sync-log", bg);
|
||||
let html = win.gBrowser.loadOneTab("http://example.com", bg);
|
||||
let png = win.gBrowser.loadOneTab("http://mochi.test:8888/browser/browser/base/content/test/moz.png", bg);
|
||||
let svg = win.gBrowser.loadOneTab("http://mochi.test:8888/browser/browser/base/content/test/title_test.svg", bg);
|
||||
|
@ -79,7 +79,7 @@ function onTabViewWindowLoaded(win) {
|
|||
check(datatext, "datatext", false);
|
||||
check(datahtml, "datahtml", false);
|
||||
check(mozilla, "about:mozilla", false);
|
||||
check(robots, "about:robots", true);
|
||||
check(synclog, "about:sync-log", true);
|
||||
check(html, "html", true);
|
||||
check(png, "png", false);
|
||||
check(svg, "svg", true);
|
||||
|
|
|
@ -79,9 +79,9 @@ function createBrowserState() {
|
|||
"2nd-group-id": {bounds: bounds, title: "new group 2", id: "2nd-group-id"}
|
||||
};
|
||||
|
||||
let tab1Data = {bounds: bounds, url: "about:robots", groupID: "2nd-group-id"};
|
||||
let tab1Data = {bounds: bounds, url: "about:rights", groupID: "2nd-group-id"};
|
||||
let tab1 = {
|
||||
entries: [{url: "about:robots"}],
|
||||
entries: [{url: "about:rights"}],
|
||||
extData: {"tabview-tab": JSON.stringify(tab1Data)}
|
||||
};
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ function onTabViewLoadedAndShown() {
|
|||
contentWindow.gPrefBranch.setBoolPref("animate_zoom", false);
|
||||
|
||||
// Create a second tab
|
||||
gBrowser.addTab("about:robots");
|
||||
gBrowser.addTab("about:mozilla");
|
||||
is(gBrowser.tabs.length, 2, "we now have 2 tabs");
|
||||
|
||||
registerCleanupFunction(function() {
|
||||
|
|
Загрузка…
Ссылка в новой задаче