Backing out Bug 544097 due to test failures.

This commit is contained in:
Kyle Huey 2010-03-09 01:16:43 -05:00
Родитель 9f31ade692 a7c3948d0a
Коммит ef9946d39a
203 изменённых файлов: 600 добавлений и 684 удалений

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

@ -171,7 +171,7 @@
<textbox id="autocomplete" type="autocomplete"
autocompletesearch="history"
value="http://mochi.test:8888/redirect-a11y.html"/>
value="http://localhost:8888/redirect-a11y.html"/>
<textbox id="autocomplete2" type="autocomplete">
<menupopup>

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

@ -33,6 +33,6 @@ function test () {
}, true);
content.location =
"http://mochi.test:8888/browser/browser/base/content/test/title_test.svg";
"http://localhost:8888/browser/browser/base/content/test/title_test.svg";
}

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

@ -11,7 +11,7 @@ function start_test_prefNotSet() {
isnot(zoomLevel, 1, "zoom level should have changed");
content.location =
"http://mochi.test:8888/browser/browser/base/content/test/moz.png";
"http://localhost:8888/browser/browser/base/content/test/moz.png";
}
function continue_test_prefNotSet () {
@ -22,7 +22,7 @@ function continue_test_prefNotSet () {
FullZoom.reset();
content.location =
"http://mochi.test:8888/browser/browser/base/content/test/zoom_test.html";
"http://localhost:8888/browser/browser/base/content/test/zoom_test.html";
}
function end_test_prefNotSet() {
@ -44,6 +44,6 @@ function test() {
tabElm.linkedBrowser.addEventListener("load", start_test_prefNotSet, true);
content.location =
"http://mochi.test:8888/browser/browser/base/content/test/zoom_test.html";
"http://localhost:8888/browser/browser/base/content/test/zoom_test.html";
}

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

@ -1,7 +1,7 @@
function test() {
waitForExplicitFinish();
let tab = gBrowser.selectedTab = gBrowser.addTab(
"http://mochi.test:8888/browser/browser/base/content/test/browser_bug479408_sample.html");
"http://localhost:8888/browser/browser/base/content/test/browser_bug479408_sample.html");
gBrowser.addEventListener("DOMLinkAdded", function(aEvent) {
gBrowser.removeEventListener("DOMLinkAdded", arguments.callee, true);

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

@ -45,22 +45,22 @@ function test() {
function addTab(aURL,aReferrer)
tabs.push(gBrowser.addTab(aURL, {referrerURI: aReferrer}));
addTab("http://mochi.test:8888/#0");
addTab("http://localhost:8888/#0");
gBrowser.selectedTab = tabs[0];
addTab("http://mochi.test:8888/#1");
addTab("http://mochi.test:8888/#2",gBrowser.currentURI);
addTab("http://mochi.test:8888/#3",gBrowser.currentURI);
addTab("http://localhost:8888/#1");
addTab("http://localhost:8888/#2",gBrowser.currentURI);
addTab("http://localhost:8888/#3",gBrowser.currentURI);
gBrowser.selectedTab = tabs[tabs.length - 1];
gBrowser.selectedTab = tabs[0];
addTab("http://mochi.test:8888/#4",gBrowser.currentURI);
addTab("http://localhost:8888/#4",gBrowser.currentURI);
gBrowser.selectedTab = tabs[3];
addTab("http://mochi.test:8888/#5",gBrowser.currentURI);
addTab("http://localhost:8888/#5",gBrowser.currentURI);
gBrowser.removeTab(tabs.pop());
addTab("about:blank",gBrowser.currentURI);
gBrowser.moveTabTo(gBrowser.selectedTab, 1);
addTab("http://mochi.test:8888/#6",gBrowser.currentURI);
addTab("http://localhost:8888/#6",gBrowser.currentURI);
addTab();
addTab("http://mochi.test:8888/#7");
addTab("http://localhost:8888/#7");
return tabs;
}

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

@ -104,7 +104,7 @@ function loaded() {
var win = wm.getMostRecentWindow("navigator:browser");
var notificationBox = win.gBrowser.getNotificationBox();
var notification = notificationBox.getNotificationWithValue("offline-app-requested-mochi.test");
var notification = notificationBox.getNotificationWithValue("offline-app-requested-localhost");
notification.childNodes[0].click();
notification = notificationBox.getNotificationWithValue("offline-app-requested-example.com");

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

@ -37,7 +37,7 @@ function finishTest() {
var pm = Components.classes["@mozilla.org/permissionmanager;1"].
getService(Components.interfaces.nsIPermissionManager);
pm.remove("mochi.test", "offline-app");
pm.remove("localhost", "offline-app");
window.removeEventListener("message", handleMessageEvents, false);
@ -103,7 +103,7 @@ function loaded() {
var notificationBox = win.gBrowser.getNotificationBox();
var notification = notificationBox
.getNotificationWithValue("offline-app-requested-mochi.test");
.getNotificationWithValue("offline-app-requested-localhost");
notification.childNodes[0].click();
}

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

@ -29,7 +29,7 @@
/* register a handler for the feed type */
const MAYBE_FEED = "application/vnd.mozilla.maybe.feed";
var handlerPage = "http://mochi.test:8888/tests/toolkit/components/places/tests/chrome/demohandler.html?feedurl=%s";
var handlerPage = "http://localhost:8888/tests/toolkit/components/places/tests/chrome/demohandler.html?feedurl=%s";
var wccr = Cc[wccrID].getService(Ci.nsIWebContentConverterService);
wccr.registerContentHandler(MAYBE_FEED, handlerPage, "Demo handler", null);
var demoHandler = wccr.getWebContentHandlerByURI(MAYBE_FEED, handlerPage);
@ -40,7 +40,7 @@
function finishUp() {
var theframe = document.getElementById('theframe');
var previewURL = "http://mochi.test:8888/tests/toolkit/components/places/tests/chrome/demohandler.html?feedurl=http%3A%2F%2Fmochi.test%3A8888%2Ftests%2Ftoolkit%2Fcomponents%2Fplaces%2Ftests%2Fchrome%2Fsample_feed.atom";
var previewURL = "http://localhost:8888/tests/toolkit/components/places/tests/chrome/demohandler.html?feedurl=http%3A%2F%2Flocalhost%3A8888%2Ftests%2Ftoolkit%2Fcomponents%2Fplaces%2Ftests%2Fchrome%2Fsample_feed.atom";
is(theframe.contentDocument.URL, previewURL);
/* remove our demoHandler */
@ -52,7 +52,7 @@
SimpleTest.finish();
}
</script>
<html:iframe src="http://mochi.test:8888/tests/toolkit/components/places/tests/chrome/sample_feed.atom" height="400px"
<html:iframe src="http://localhost:8888/tests/toolkit/components/places/tests/chrome/sample_feed.atom" height="400px"
id="theframe" onload="finishUp();">
</html:iframe>
</window>
</window>

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

@ -40,12 +40,12 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=402788
ok(navigator.registerContentHandler, "navigator.registerContentHandler should be defined");
// testing a generic case
is(true, testRegisterHandler(true, "foo", "http://mochi.test:8888/%s", "Foo handler"), "registering a foo protocol handler should work");
is(true, testRegisterHandler(false, "application/rss+xml", "http://mochi.test:8888/%s", "Foo handler"), "registering a foo content handler should work");
is(true, testRegisterHandler(true, "foo", "http://localhost:8888/%s", "Foo handler"), "registering a foo protocol handler should work");
is(true, testRegisterHandler(false, "application/rss+xml", "http://localhost:8888/%s", "Foo handler"), "registering a foo content handler should work");
// testing with wrong uris
is(false, testRegisterHandler(true, "foo", "http://mochi.test:8888/", "Foo handler"), "a protocol handler uri should contain %s");
is(false, testRegisterHandler(false, "application/rss+xml", "http://mochi.test:8888/", "Foo handler"), "a content handler uri should contain %s");
is(false, testRegisterHandler(true, "foo", "http://localhost:8888/", "Foo handler"), "a protocol handler uri should contain %s");
is(false, testRegisterHandler(false, "application/rss+xml", "http://localhost:8888/", "Foo handler"), "a content handler uri should contain %s");
// the spec says we should not throw here, but it probably needs to be changed
is(false, testRegisterHandler(true, "foo", "foo/%s", "Foo handler"), "a protocol handler uri should be valid");
@ -57,28 +57,28 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=402788
// restriction to http(s) for the uri of the handler (bug 401343)
// https should work (http already tested in the generic case)
is(true, testRegisterHandler(true, "foo", "https://mochi.test:8888/%s", "Foo handler"), "registering a foo protocol handler with https scheme should work");
is(true, testRegisterHandler(false, "application/rss+xml", "https://mochi.test:8888/%s", "Foo handler"), "registering a foo content handler with https scheme should work");
is(true, testRegisterHandler(true, "foo", "https://localhost:8888/%s", "Foo handler"), "registering a foo protocol handler with https scheme should work");
is(true, testRegisterHandler(false, "application/rss+xml", "https://localhost:8888/%s", "Foo handler"), "registering a foo content handler with https scheme should work");
// ftp should not work
is(false, testRegisterHandler(true, "foo", "ftp://mochi.test:8888/%s", "Foo handler"), "registering a foo protocol handler with ftp scheme should not work");
is(false, testRegisterHandler(false, "application/rss+xml", "ftp://mochi.test:8888/%s", "Foo handler"), "registering a foo content handler with ftp scheme should not work");
is(false, testRegisterHandler(true, "foo", "ftp://localhost:8888/%s", "Foo handler"), "registering a foo protocol handler with ftp scheme should not work");
is(false, testRegisterHandler(false, "application/rss+xml", "ftp://localhost:8888/%s", "Foo handler"), "registering a foo content handler with ftp scheme should not work");
// chrome should not work
is(false, testRegisterHandler(true, "foo", "chrome://mochi.test:8888/%s", "Foo handler"), "registering a foo protocol handler with chrome scheme should not work");
is(false, testRegisterHandler(false, "application/rss+xml", "chrome://mochi.test:8888/%s", "Foo handler"), "registering a foo content handler with chrome scheme should not work");
is(false, testRegisterHandler(true, "foo", "chrome://localhost:8888/%s", "Foo handler"), "registering a foo protocol handler with chrome scheme should not work");
is(false, testRegisterHandler(false, "application/rss+xml", "chrome://localhost:8888/%s", "Foo handler"), "registering a foo content handler with chrome scheme should not work");
// foo should not work
is(false, testRegisterHandler(true, "foo", "foo://mochi.test:8888/%s", "Foo handler"), "registering a foo protocol handler with foo scheme should not work");
is(false, testRegisterHandler(false, "application/rss+xml", "foo://mochi.test:8888/%s", "Foo handler"), "registering a foo content handler with foo scheme should not work");
is(false, testRegisterHandler(true, "foo", "foo://localhost:8888/%s", "Foo handler"), "registering a foo protocol handler with foo scheme should not work");
is(false, testRegisterHandler(false, "application/rss+xml", "foo://localhost:8888/%s", "Foo handler"), "registering a foo content handler with foo scheme should not work");
// for security reasons, protocol handlers should never be registered for some schemes (chrome, vbscript, ...) (bug 402788)
is(false, testRegisterHandler(true, "chrome", "http://mochi.test:8888/%s", "chrome handler"), "registering a chrome protocol handler should not work");
is(false, testRegisterHandler(true, "vbscript", "http://mochi.test:8888/%s", "vbscript handler"), "registering a vbscript protocol handler should not work");
is(false, testRegisterHandler(true, "javascript", "http://mochi.test:8888/%s", "javascript handler"), "registering a javascript protocol handler should not work");
is(false, testRegisterHandler(true, "moz-icon", "http://mochi.test:8888/%s", "moz-icon handler"), "registering a moz-icon protocol handler should not work");
is(false, testRegisterHandler(true, "chrome", "http://localhost:8888/%s", "chrome handler"), "registering a chrome protocol handler should not work");
is(false, testRegisterHandler(true, "vbscript", "http://localhost:8888/%s", "vbscript handler"), "registering a vbscript protocol handler should not work");
is(false, testRegisterHandler(true, "javascript", "http://localhost:8888/%s", "javascript handler"), "registering a javascript protocol handler should not work");
is(false, testRegisterHandler(true, "moz-icon", "http://localhost:8888/%s", "moz-icon handler"), "registering a moz-icon protocol handler should not work");
// for security reasons, content handlers should never be registered for some types (html, ...)
is(true, testRegisterHandler(false, "application/rss+xml", "http://mochi.test:8888/%s", "Foo handler"), "registering rss content handlers should work");
is(true, testRegisterHandler(false, "application/atom+xml", "http://mochi.test:8888/%s", "Foo handler"), "registering atom content handlers should work");
todo(false, testRegisterHandler(false, "text/html", "http://mochi.test:8888/%s", "Foo handler"), "registering html content handlers should not work"); // bug 403798
is(true, testRegisterHandler(false, "application/rss+xml", "http://localhost:8888/%s", "Foo handler"), "registering rss content handlers should work");
is(true, testRegisterHandler(false, "application/atom+xml", "http://localhost:8888/%s", "Foo handler"), "registering atom content handlers should work");
todo(false, testRegisterHandler(false, "text/html", "http://localhost:8888/%s", "Foo handler"), "registering html content handlers should not work"); // bug 403798
</script>
</pre>

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

@ -129,7 +129,7 @@ function addDownload(dm, aParams)
aParams.targetFile.append(aParams.resultFileName);
}
if (!("sourceURI" in aParams))
aParams.sourceURI = "http://mochi.test:8888/browser/browser/components/privatebrowsing/test/browser/staller.sjs";
aParams.sourceURI = "http://localhost:8888/browser/browser/components/privatebrowsing/test/browser/staller.sjs";
if (!("downloadName" in aParams))
aParams.downloadName = null;
if (!("runBeforeStart" in aParams))

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

@ -43,7 +43,7 @@ function test() {
let pb = Cc["@mozilla.org/privatebrowsing;1"].
getService(Ci.nsIPrivateBrowsingService);
const testPageURL = "http://mochi.test:8888/browser/" +
const testPageURL = "http://localhost:8888/browser/" +
"browser/components/privatebrowsing/test/browser/browser_privatebrowsing_geoprompt_page.html";
waitForExplicitFinish();

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

@ -51,7 +51,7 @@ function test() {
getService(Ci.nsICookieManager);
waitForExplicitFinish();
const TEST_URL = "http://mochi.test:8888/browser/browser/components/privatebrowsing/test/browser/title.sjs";
const TEST_URL = "http://localhost:8888/browser/browser/components/privatebrowsing/test/browser/title.sjs";
function cleanup() {
// delete all history items

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

@ -46,7 +46,7 @@ function test() {
let oldPopupPolicy = gPrefService.getBoolPref("dom.disable_open_during_load");
gPrefService.setBoolPref("dom.disable_open_during_load", true);
const TEST_URI = "http://mochi.test:8888/browser/browser/components/privatebrowsing/test/browser/popup.html";
const TEST_URI = "http://localhost:8888/browser/browser/components/privatebrowsing/test/browser/popup.html";
waitForExplicitFinish();

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

@ -44,7 +44,7 @@ function test() {
let pb = Cc["@mozilla.org/privatebrowsing;1"].
getService(Ci.nsIPrivateBrowsingService);
const testPageURL = "http://mochi.test:8888/browser/" +
const testPageURL = "http://localhost:8888/browser/" +
"browser/components/privatebrowsing/test/browser/browser_privatebrowsing_windowtitle_page.html";
waitForExplicitFinish();

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

@ -4,8 +4,8 @@
<Description>426329 Search</Description>
<InputEncoding>utf-8</InputEncoding>
<Image width="16" height="16">data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABGklEQVQoz2NgGB6AnZ1dUlJSXl4eSDIyMhLW4Ovr%2B%2Fr168uXL69Zs4YoG%2BLi4i5dusTExMTGxsbNzd3f37937976%2BnpmZmagbHR09J49e5YvX66kpATVEBYW9ubNm2nTphkbG7e2tp44cQLIuHfvXm5urpaWFlDKysqqu7v73LlzECMYIiIiHj58mJCQoKKicvXq1bS0NKBgW1vbjh074uPjgeqAXE1NzSdPnvDz84M0AEUvXLgAsW379u1z5swBen3jxo2zZ892cHB4%2BvQp0KlAfwI1cHJyghQFBwfv2rULokFXV%2FfixYu7d%2B8GGqGgoMDKyrpu3br9%2B%2FcDuXl5eVA%2FAEWBfoWHAdAYoNuAYQ0XAeoUERFhGDYAAPoUaT2dfWJuAAAAAElFTkSuQmCC</Image>
<Url type="text/html" method="GET" template="http://mochi.test:8888/browser/browser/components/search/test/test.html">
<Url type="text/html" method="GET" template="http://localhost:8888/browser/browser/components/search/test/test.html">
<Param name="test" value="{searchTerms}"/>
</Url>
<moz:SearchForm>http://mochi.test:8888/browser/browser/components/search/test/test.html</moz:SearchForm>
<moz:SearchForm>http://localhost:8888/browser/browser/components/search/test/test.html</moz:SearchForm>
</OpenSearchDescription>

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

@ -3,7 +3,7 @@
<ShortName>483086a</ShortName>
<Description>Bug 483086 Test 1</Description>
<Image width="16" height="16">data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABGklEQVQoz2NgGB6AnZ1dUlJSXl4eSDIyMhLW4Ovr%2B%2Fr168uXL69Zs4YoG%2BLi4i5dusTExMTGxsbNzd3f37937976%2BnpmZmagbHR09J49e5YvX66kpATVEBYW9ubNm2nTphkbG7e2tp44cQLIuHfvXm5urpaWFlDKysqqu7v73LlzECMYIiIiHj58mJCQoKKicvXq1bS0NKBgW1vbjh074uPjgeqAXE1NzSdPnvDz84M0AEUvXLgAsW379u1z5swBen3jxo2zZ892cHB4%2BvQp0KlAfwI1cHJyghQFBwfv2rULokFXV%2FfixYu7d%2B8GGqGgoMDKyrpu3br9%2B%2FcDuXl5eVA%2FAEWBfoWHAdAYoNuAYQ0XAeoUERFhGDYAAPoUaT2dfWJuAAAAAElFTkSuQmCC</Image>
<Url type="text/html" method="GET" template="http://mochi.test:8888/browser/browser/components/search/test/?search">
<Url type="text/html" method="GET" template="http://localhost:8888/browser/browser/components/search/test/?search">
<Param name="test" value="{searchTerms}"/>
</Url>
<moz:SearchForm>foo://example.com</moz:SearchForm>

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

@ -3,7 +3,7 @@
<ShortName>483086b</ShortName>
<Description>Bug 483086 Test 2</Description>
<Image width="16" height="16">data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABGklEQVQoz2NgGB6AnZ1dUlJSXl4eSDIyMhLW4Ovr%2B%2Fr168uXL69Zs4YoG%2BLi4i5dusTExMTGxsbNzd3f37937976%2BnpmZmagbHR09J49e5YvX66kpATVEBYW9ubNm2nTphkbG7e2tp44cQLIuHfvXm5urpaWFlDKysqqu7v73LlzECMYIiIiHj58mJCQoKKicvXq1bS0NKBgW1vbjh074uPjgeqAXE1NzSdPnvDz84M0AEUvXLgAsW379u1z5swBen3jxo2zZ892cHB4%2BvQp0KlAfwI1cHJyghQFBwfv2rULokFXV%2FfixYu7d%2B8GGqGgoMDKyrpu3br9%2B%2FcDuXl5eVA%2FAEWBfoWHAdAYoNuAYQ0XAeoUERFhGDYAAPoUaT2dfWJuAAAAAElFTkSuQmCC</Image>
<Url type="text/html" method="GET" template="http://mochi.test:8888/browser/browser/components/search/test/?search">
<Url type="text/html" method="GET" template="http://localhost:8888/browser/browser/components/search/test/?search">
<Param name="test" value="{searchTerms}"/>
</Url>
<moz:SearchForm>http://example.com</moz:SearchForm>

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

@ -56,7 +56,7 @@ function test() {
waitForExplicitFinish();
gObs.addObserver(observers, "browser-search-engine-modified", false);
gSS.addEngine("http://mochi.test:8888/browser/browser/components/search/test/testEngine.xml",
gSS.addEngine("http://localhost:8888/browser/browser/components/search/test/testEngine.xml",
Ci.nsISearchEngine.DATA_XML, "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABGklEQVQoz2NgGB6AnZ1dUlJSXl4eSDIyMhLW4Ovr%2B%2Fr168uXL69Zs4YoG%2BLi4i5dusTExMTGxsbNzd3f37937976%2BnpmZmagbHR09J49e5YvX66kpATVEBYW9ubNm2nTphkbG7e2tp44cQLIuHfvXm5urpaWFlDKysqqu7v73LlzECMYIiIiHj58mJCQoKKicvXq1bS0NKBgW1vbjh074uPjgeqAXE1NzSdPnvDz84M0AEUvXLgAsW379u1z5swBen3jxo2zZ892cHB4%2BvQp0KlAfwI1cHJyghQFBwfv2rULokFXV%2FfixYu7d%2B8GGqGgoMDKyrpu3br9%2B%2FcDuXl5eVA%2FAEWBfoWHAdAYoNuAYQ0XAeoUERFhGDYAAPoUaT2dfWJuAAAAAElFTkSuQmCC",
false);
}

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

@ -33,7 +33,7 @@ function test() {
}
obs.addObserver(observer, "browser-search-engine-modified", false);
ss.addEngine("http://mochi.test:8888/browser/browser/components/search/test/426329.xml",
ss.addEngine("http://localhost:8888/browser/browser/components/search/test/426329.xml",
Ci.nsISearchEngine.DATA_XML, "data:image/x-icon,%00",
false);

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

@ -58,7 +58,7 @@ function test() {
}
gObs.addObserver(observer, "browser-search-engine-modified", false);
gSS.addEngine("http://mochi.test:8888/browser/browser/components/search/test/483086-1.xml",
gSS.addEngine("http://localhost:8888/browser/browser/components/search/test/483086-1.xml",
Ci.nsISearchEngine.DATA_XML, "data:image/x-icon;%00",
false);
}
@ -80,7 +80,7 @@ function test2() {
}
gObs.addObserver(observer, "browser-search-engine-modified", false);
gSS.addEngine("http://mochi.test:8888/browser/browser/components/search/test/483086-2.xml",
gSS.addEngine("http://localhost:8888/browser/browser/components/search/test/483086-2.xml",
Ci.nsISearchEngine.DATA_XML, "data:image/x-icon;%00",
false);
}

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

@ -4,9 +4,9 @@
<Description>Foo Search</Description>
<InputEncoding>utf-8</InputEncoding>
<Image width="16" height="16">data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABGklEQVQoz2NgGB6AnZ1dUlJSXl4eSDIyMhLW4Ovr%2B%2Fr168uXL69Zs4YoG%2BLi4i5dusTExMTGxsbNzd3f37937976%2BnpmZmagbHR09J49e5YvX66kpATVEBYW9ubNm2nTphkbG7e2tp44cQLIuHfvXm5urpaWFlDKysqqu7v73LlzECMYIiIiHj58mJCQoKKicvXq1bS0NKBgW1vbjh074uPjgeqAXE1NzSdPnvDz84M0AEUvXLgAsW379u1z5swBen3jxo2zZ892cHB4%2BvQp0KlAfwI1cHJyghQFBwfv2rULokFXV%2FfixYu7d%2B8GGqGgoMDKyrpu3br9%2B%2FcDuXl5eVA%2FAEWBfoWHAdAYoNuAYQ0XAeoUERFhGDYAAPoUaT2dfWJuAAAAAElFTkSuQmCC</Image>
<Url type="text/html" method="GET" template="http://mochi.test:8888/browser/browser/components/search/test/?search">
<Url type="text/html" method="GET" template="http://localhost:8888/browser/browser/components/search/test/?search">
<Param name="test" value="{searchTerms}"/>
</Url>
<moz:SearchForm>http://mochi.test:8888/browser/browser/components/search/test/</moz:SearchForm>
<moz:SearchForm>http://localhost:8888/browser/browser/components/search/test/</moz:SearchForm>
<moz:Alias>fooalias</moz:Alias>
</OpenSearchDescription>

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

@ -115,7 +115,7 @@ function test() {
this.removeEventListener("load", arguments.callee, true);
// private browsing session, add new tab: (C)
const testURL_C = "http://mochi.test:8888/";
const testURL_C = "http://localhost:8888/";
let tab_C = gBrowser.addTab(testURL_C);
tab_C.linkedBrowser.addEventListener("load", function (aEvent) {

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

@ -114,7 +114,7 @@ function test() {
const testURL = "chrome://mochikit/content/browser/" +
"browser/components/sessionstore/test/browser/browser_248970_b_sample.html";
const testURL2 = "http://mochi.test:8888/browser/" +
const testURL2 = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_248970_b_sample.html";
// get closed tab count

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_339445_sample.html";
let tab = gBrowser.addTab(testURL);

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

@ -63,7 +63,7 @@ function test() {
// the interval pref to 0
gPrefService.setIntPref("browser.sessionstore.interval", 0);
const testURL = "http://mochi.test:8888/browser/" +
const testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_423132_sample.html";
// open a new window

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

@ -40,7 +40,7 @@ function test() {
// test setup
let ss = Cc["@mozilla.org/browser/sessionstore;1"].getService(Ci.nsISessionStore);
waitForExplicitFinish();
const baseURL = "http://mochi.test:8888/browser/" +
const baseURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_447951_sample.html#";
let tab = gBrowser.addTab();

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_459906_sample.html";
let uniqueValue = "<b>Unique:</b> " + Date.now();
@ -81,7 +81,7 @@ function test() {
innerDomain = iframes[0].document.domain;
}
catch (ex) { /* throws for chrome: documents */ }
is(innerDomain, "mochi.test", "XSS exploit prevented!");
is(innerDomain, "localhost", "XSS exploit prevented!");
// clean up
gBrowser.removeTab(tab2);

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_461743_sample.html";
let frameCount = 0;

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

@ -17,7 +17,7 @@
}
else {
frames[1].document.location.hash = "#original";
frames[0].document.location = "http://mochi.test:8888/browser/" +
frames[0].document.location = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_463205_helper.html";
}
}, false);

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_463206_sample.html";
var frameCount = 0;

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

@ -6,7 +6,7 @@
<iframe onload="setup()"></iframe>
<script>
var targetUrl = "http://mochi.test:8888/browser/" +
var targetUrl = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_464620_xd.html";
var firstPass;

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_464620_a.html";
var frameCount = 0;

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

@ -7,7 +7,7 @@
<iframe onload="setup()"></iframe>
<script>
var targetUrl = "http://mochi.test:8888/browser/" +
var targetUrl = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_464620_xd.html";
var firstPass;

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_464620_b.html";
var frameCount = 0;

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_466937_sample.html";
let testPath = "/home/user/regular.file";

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

@ -39,7 +39,7 @@ function test() {
waitForExplicitFinish();
let testURL = "http://mochi.test:8888/browser/" +
let testURL = "http://localhost:8888/browser/" +
"browser/components/sessionstore/test/browser/browser_476161_sample.html";
let tab = gBrowser.addTab(testURL);
tab.linkedBrowser.addEventListener("load", function(aEvent) {

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

@ -57,9 +57,9 @@ function test() {
is(doc.URL, "about:blank", "loaded page is about:blank");
// Test that starting a new session loads the homepage (set to http://mochi.test:8888)
// Test that starting a new session loads the homepage (set to http://localhost:8888)
// if Firefox is configured to display a homepage at startup (browser.startup.page = 1)
let homepage = "http://mochi.test:8888/";
let homepage = "http://localhost:8888/";
gPrefService.setCharPref("browser.startup.homepage", homepage);
gPrefService.setIntPref("browser.startup.page", 1);
gBrowser.loadURI("about:sessionrestore");

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

@ -274,7 +274,7 @@ user_pref("network.http.prompt-temp-redirect", false);
user_pref("media.cache_size", 100);
user_pref("security.warn_viewing_mixed", false);
user_pref("geo.wifi.uri", "http://mochi.test:8888/tests/dom/tests/mochitest/geolocation/network_geolocation.sjs");
user_pref("geo.wifi.uri", "http://localhost:8888/tests/dom/tests/mochitest/geolocation/network_geolocation.sjs");
user_pref("geo.wifi.testing", true);
user_pref("camino.warn_when_closing", false); // Camino-only, harmless to others
@ -282,10 +282,10 @@ user_pref("camino.warn_when_closing", false); // Camino-only, harmless to others
// Make url-classifier updates so rare that they won't affect tests
user_pref("urlclassifier.updateinterval", 172800);
// Point the url-classifier to the local testing server for fast failures
user_pref("browser.safebrowsing.provider.0.gethashURL", "http://mochi.test:8888/safebrowsing-dummy/gethash");
user_pref("browser.safebrowsing.provider.0.keyURL", "http://mochi.test:8888/safebrowsing-dummy/newkey");
user_pref("browser.safebrowsing.provider.0.lookupURL", "http://mochi.test:8888/safebrowsing-dummy/lookup");
user_pref("browser.safebrowsing.provider.0.updateURL", "http://mochi.test:8888/safebrowsing-dummy/update");
user_pref("browser.safebrowsing.provider.0.gethashURL", "http://localhost:8888/safebrowsing-dummy/gethash");
user_pref("browser.safebrowsing.provider.0.keyURL", "http://localhost:8888/safebrowsing-dummy/newkey");
user_pref("browser.safebrowsing.provider.0.lookupURL", "http://localhost:8888/safebrowsing-dummy/lookup");
user_pref("browser.safebrowsing.provider.0.updateURL", "http://localhost:8888/safebrowsing-dummy/update");
"""
prefs.append(part)

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

@ -72,25 +72,7 @@ if __name__ == '__main__':
t.setDaemon(True)
t.start()
# since this requires localhost, we cannot use automation.initializeProfile
try:
os.makedirs(PROFILE_DIRECTORY)
except:
pass # leaf directory already exists
prefsFile = open(PROFILE_DIRECTORY + "/" + "user.js", "w")
prefsFile.write('user_pref("dom.popup_maximum", -1);')
prefsFile.write('user_pref("dom.disable_open_during_load", false);')
prefsFile.write('user_pref("browser.shell.checkDefaultBrowser", false);')
prefsFile.write('user_pref("browser.warnOnQuit", false);')
prefsFile.write('user_pref("dom.allow_scripts_to_close_windows", true);')
prefsFile.write('user_pref("capability.principal.codebase.p0.granted", \
"UniversalXPConnect UniversalBrowserRead UniversalBrowserWrite \
UniversalPreferencesRead UniversalPreferencesWrite UniversalFileRead");\n')
prefsFile.write('user_pref("capability.principal.codebase.p0.id", "http://localhost:%s");\n' % PORT)
prefsFile.write('user_pref("capability.principal.codebase.p0.subjectName", "");\n')
prefsFile.close()
automation.initializeProfile(PROFILE_DIRECTORY)
browserEnv = automation.environment()
if not "XPCOM_DEBUG_BREAK" in browserEnv:

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

@ -75,20 +75,12 @@
#
# This is the primary location from which tests run.
#
http://mochi.test:8888 primary,privileged
http://localhost:8888 primary,privileged
#
# These are a common set of prefixes scattered across one TLD with two ports and
# another TLD on a single port.
#
http://127.0.0.1:80 privileged
http://127.0.0.1:8888 privileged
http://moztest:80 privileded
http://mochi.test:80 privileged
http://mochi.test:8000 privileged
http://mochi.test:8080 privileged
http://mochi.test:8888 privileged
http://mochi.test:4444 privileged
http://example.org:80 privileged
http://test1.example.org:80 privileged
http://test2.example.org:80 privileged

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

@ -1,4 +1,4 @@
function handleRequest(request, response) {
response.setStatusLine(null, 302, "Found");
response.setHeader("Location", "http://mochi.test:8888/tests/content/base/test/bug461735-post-redirect.js", false);
response.setHeader("Location", "http://localhost:8888/tests/content/base/test/bug461735-post-redirect.js", false);
}

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

@ -22,7 +22,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=421622
<script type="application/javascript"><![CDATA[
/** Test for Bug 421622 **/
const SJS_URL = "http://mochi.test:8888/tests/content/base/test/chrome/bug421622-referer.sjs";
const SJS_URL = "http://localhost:8888/tests/content/base/test/chrome/bug421622-referer.sjs";
const REFERER_URL = "http://www.mozilla.org/";
var req = new XMLHttpRequest();

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

@ -22,11 +22,9 @@ function handleRequest(request, response)
// -- anything served from other hosts (example.com:80) will be blocked.
// -- XHR tests are set up in the file_CSP_main.js file which is sourced.
response.setHeader("X-Content-Security-Policy",
"allow mochi.test",
"allow 'self'",
false);
var proxyURI = "http://" + query["proxy"];
xhr.open("GET", proxyURI + "/tests/content/base/test/file_CSP_main.html", false);
xhr.open("GET", "http://localhost:8888/tests/content/base/test/file_CSP_main.html", false);
xhr.send(null);
if(xhr.status == 200) {
response.write(xhr.responseText);

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

@ -5,11 +5,11 @@ function setupFrames() {
var $ = function(v) { return document.getElementById(v); }
var base = {
self: '/tests/content/base/test/file_CSP_frameancestors.sjs',
a: 'http://mochi.test:8888/tests/content/base/test/file_CSP_frameancestors.sjs',
a: 'http://localhost:8888/tests/content/base/test/file_CSP_frameancestors.sjs',
b: 'http://example.com/tests/content/base/test/file_CSP_frameancestors.sjs'
};
var host = { a: 'http://mochi.test:8888', b: 'http://example.com:80' };
var host = { a: 'http://localhost:8888', b: 'http://example.com:80' };
var innerframeuri = null;
var elt = null;

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

@ -3,7 +3,7 @@
try {
var xhr_good = new XMLHttpRequest();
var xhr_good_uri ="http://mochi.test:8888/tests/content/base/test/file_CSP.sjs?testid=xhr_good";
var xhr_good_uri ="http://localhost:8888/tests/content/base/test/file_CSP.sjs?testid=xhr_good";
xhr_good.open("GET", xhr_good_uri, true);
xhr_good.send(null);
} catch(e) {}

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

@ -79,7 +79,7 @@ window.addEventListener("message", function(e) {
}, false);
function post(e, res) {
e.source.postMessage(res.toSource(), "http://mochi.test:8888");
e.source.postMessage(res.toSource(), "http://localhost:8888");
}
</script>
@ -87,4 +87,4 @@ function post(e, res) {
<body>
Inner page
</body>
</html>
</html>

Двоичные данные
content/base/test/file_CrossSiteXHR_inner.jar

Двоичный файл не отображается.

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

@ -11,7 +11,7 @@ adipiscing elit. Nam eu sapien. Sed viverra lacus. Donec quis ipsum.
Nunc cursus aliquet lectus. Nunc vitae eros. Class aptent taciti <span>sociosqu
ad
litora</span> torquent <a
href="http://mochi.test:8888/tests/content/base/test/file_htmlserializer_1_result1.html">per
href="http://localhost:8888/tests/content/base/test/file_htmlserializer_1_result1.html">per
conubia</a>
nostra, per inceptos hymenaeos. </p>
@ -50,4 +50,4 @@ ut gravida eros leo ut libero
<noscript>
<p>Curabitur consectetuer urna a sem. Nunc & non urna. Cras in massa. Vestibulum ante ipsum primis in faucibus orci luctus</p></noscript>
<p>Nam eu sapien. Sed viverra lacus. Donec quis ipsum. Nunc cursus
aliquet lectus. Nunc vitae eros. Class aptent taciti</p></body></html>
aliquet lectus. Nunc vitae eros. Class aptent taciti</p></body></html>

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

@ -57,4 +57,4 @@ ut gravida eros <br />leo ut libero
lacus risus pulvinar ante.
</pre>
</body>
</html>
</html>

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

@ -14,7 +14,7 @@ adipiscing elit. Nam eu sapien. Sed viverra lacus. Donec quis ipsum.
Nunc cursus aliquet lectus. Nunc vitae eros. Class aptent taciti <span>sociosqu
ad
litora</span> torquent <a
href="http://mochi.test:8888/tests/content/base/test/file_htmlserializer_1_result1.html">per
href="http://localhost:8888/tests/content/base/test/file_htmlserializer_1_result1.html">per
conubia</a>
nostra, per inceptos hymenaeos. </p>
@ -68,4 +68,4 @@ pharetra rutrum, <br/>
lacus risus pulvinar ante.
</pre>
</body>
</html>
</html>

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

@ -119,15 +119,7 @@ SimpleTest.waitForExplicitFinish();
// save this for last so that our listeners are registered.
// ... this loads the testbed of good and bad requests.
netscape.security.PrivilegeManager.enablePrivilege('UniversalXPConnect');
var ios = Components.classes["@mozilla.org/network/io-service;1"].getService(Components.interfaces.nsIIOService);
var pps = Components.classes["@mozilla.org/network/protocol-proxy-service;1"].getService();
var uri = ios.newURI("http://example.com", null, null);
var pi = pps.resolve(uri, 0);
var proxy = pi.host + ":" + pi.port;
document.getElementById('cspframe').src = 'file_CSP.sjs?main=1&proxy=' + proxy;
document.getElementById('cspframe').src = 'file_CSP.sjs?main=1';
</script>
</pre>

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

@ -68,7 +68,7 @@ function runTest() {
// Test preflight-less requests
basePath = "/tests/content/base/test/file_CrossSiteXHR_server.sjs?"
baseURL = "http://mochi.test:8888" + basePath;
baseURL = "http://localhost:8888" + basePath;
if (!runOriginTests) {
origins = [];

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

@ -419,7 +419,7 @@ function runTest() {
},
];
baseURL = "http://mochi.test:8888/tests/content/base/test/" +
baseURL = "http://localhost:8888/tests/content/base/test/" +
"file_CrossSiteXHR_cache_server.sjs?";
setStateURL = baseURL + "setState=";

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

@ -31,13 +31,13 @@ function runTest() {
is(document.baseURI, "http://example.org/", "wrong doc baseURI");
xhr = new XMLHttpRequest;
xhr.open("GET", "http://mochi.test:8888/tests/content/base/test/file_XHRDocURI.xml");
xhr.open("GET", "http://localhost:8888/tests/content/base/test/file_XHRDocURI.xml");
xhr.onreadystatechange = function(e) {
if (!xhr.responseXML)
return;
is(xhr.responseXML.documentURI, "http://mochi.test:8888/tests/content/base/test/file_XHRDocURI.xml",
is(xhr.responseXML.documentURI, "http://localhost:8888/tests/content/base/test/file_XHRDocURI.xml",
"wrong url");
is(xhr.responseXML.baseURI, "http://mochi.test:8888/tests/content/base/test/file_XHRDocURI.xml",
is(xhr.responseXML.baseURI, "http://localhost:8888/tests/content/base/test/file_XHRDocURI.xml",
"wrong base");
if (xhr.readyState == 4) {
gen.next();
@ -48,7 +48,7 @@ function runTest() {
xhr = new XMLHttpRequest;
xhr.open("GET", "http://mochi.test:8888/tests/content/base/test/file_XHRDocURI.text");
xhr.open("GET", "http://localhost:8888/tests/content/base/test/file_XHRDocURI.text");
xhr.onreadystatechange = function(e) {
is(xhr.responseXML, null, "should not have document");
if (xhr.readyState == 4)

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

@ -15,7 +15,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=345339
<div id="content" style="display: none">
</div>
<iframe id="testframe"
src="http://mochi.test:8888/tests/content/base/test/345339_iframe.html">
src="http://localhost:8888/tests/content/base/test/345339_iframe.html">
</iframe>
<pre id="test">
<script class="testbody" type="text/javascript">

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

@ -14,7 +14,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=398243
<p id="display"></p>
<div id="content" style="display: none">
</div>
<iframe id="testframe" src="http://mochi.test:8888/tests/content/base/test/formReset.html"></iframe>
<iframe id="testframe" src="http://localhost:8888/tests/content/base/test/formReset.html"></iframe>
<pre id="test">
<script class="testbody" type="text/javascript">
/** Test for Bug 398243 **/

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

@ -114,7 +114,7 @@ function testHtmlSerializer_1 () {
//------------ OutputAbsoluteLinks
encoder.init(doc, "application/xhtml+xml", de.OutputLFLineBreak | de.OutputAbsoluteLinks);
out = encoder.encodeToString();
expected = loadFileContent("file_xhtmlserializer_1_links.xhtml").trim('\n');
expected = loadFileContent("file_xhtmlserializer_1_links.xhtml");
is(out, expected, "test OutputAbsoluteLinks");
//------------ OutputLFLineBreak

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

@ -26,7 +26,7 @@ var isupports_string = Components.classes["@mozilla.org/supports-string;1"]
.createInstance(Components.interfaces.nsISupportsString);
isupports_string.data = "foo";
const url = "http://mochi.test:8888";
const url = "http://localhost:8888";
var body = [
document,
"foo",

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

@ -120,7 +120,7 @@ function testHtmlSerializer_1 () {
//------------ OutputAbsoluteLinks
encoder.init(doc, "text/html", de.OutputLFLineBreak | de.OutputAbsoluteLinks);
out = encoder.encodeToString();
expected = loadFileContent("file_htmlserializer_1_links.html").trim('\n');
expected = loadFileContent("file_htmlserializer_1_links.html");
isRoughly(out, expected, "test OutputAbsoluteLinks");
//------------ OutputLFLineBreak

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

@ -27,7 +27,7 @@ window.onerror = function(message, uri, line) {
<script type="application/javascript">
window.onerror = function(message, uri, line) {
is(message, "c is not defined", "Should have correct error message");
is(uri, "http://mochi.test:8888/tests/content/base/test/bug461735-post-redirect.js", "Unexpected error location URI");
is(uri, "http://localhost:8888/tests/content/base/test/bug461735-post-redirect.js", "Unexpected error location URI");
is(line, 3, "Should have a line here");
}
</script>

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

@ -14,7 +14,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=475156
SimpleTest.waitForExplicitFinish();
var path = "http://mochi.test:8888/tests/content/base/test/";
var path = "http://localhost:8888/tests/content/base/test/";
function fromCache(xhr)
{

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

@ -12,7 +12,7 @@ function load() {
// our new <base> will take precedence and the test will pass.
document.open();
document.write("<html><body><a id='link' href='/'>A</a>" +
"<base href='http://mochi.test:8888' /></body></html>");
"<base href='http://localhost:8888' /></body></html>");
// Tell our parent to have a look at us.
parent.gGen.next();

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

@ -128,7 +128,7 @@ function run() {
yield; // wait for onload to fire.
// Make sure things are what as we expect them at the beginning.
link123HrefIs("http://mochi.test:8888/", 1);
link123HrefIs("http://localhost:8888/", 1);
is($('link4').href, loc + "#", "link 4 test 1");
is($('link5').href, loc + "#", "link 5 test 1");
@ -162,15 +162,15 @@ function run() {
$('base1').href = "foo/";
// Should be interpreted relative to current URI (not the current base), so
// base should now be http://mochi.test:8888/foo/
// base should now be http://localhost:8888/foo/
link123HrefIs("http://mochi.test:8888/", 3);
link123HrefIs("http://localhost:8888/", 3);
is($('link4').href, path + "foo/#", "link 4 test 3");
// Changing base2 shouldn't affect anything, because it's not the first base
// tag.
$('base2').href = "http://example.org/bar/";
link123HrefIs("http://mochi.test:8888/", 4);
link123HrefIs("http://localhost:8888/", 4);
is($('link4').href, path + "foo/#", "link 4 test 4");
// If we unset base1's href attribute, the document's base should come from
@ -206,13 +206,13 @@ function run() {
base3.parentNode.removeChild(base3);
base4.parentNode.removeChild(base4);
link123HrefIs("http://mochi.test:8888/", 9);
link123HrefIs("http://localhost:8888/", 9);
is($('link4').href, loc + "#", "link 4 test 9");
// Setting the href of base0 shouldn't do anything because it's not in the
// XHTML namespace.
$('base0').href = "http://bar.com";
link123HrefIs("http://mochi.test:8888/", 10);
link123HrefIs("http://localhost:8888/", 10);
is($('link4').href, loc + "#", "link 4 test 10");
// We load into an iframe a document with a <base href="...">, then remove
@ -231,7 +231,7 @@ function run() {
iframeCw.location = "file_bug209275_2.html";
yield; // wait for callback from child
is(iframeCw.document.getElementById("link").href,
"http://mochi.test:8888/",
"http://localhost:8888/",
"Wrong href after nuking document second time.");
// Make sure that document.open() makes the document forget about any <base>
@ -239,7 +239,7 @@ function run() {
iframeCw.location = "file_bug209275_3.html";
yield; // wait for callback from child
is(iframeCw.document.getElementById("link").href,
"http://mochi.test:8888/",
"http://localhost:8888/",
"Wrong href after document.open().");
SimpleTest.finish();

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

@ -32,7 +32,7 @@
SimpleTest.waitForExplicitFinish();
function doCheck(){
is(frames['submit_frame'].location.href, "http://mochi.test:8888/blah?field1=teststring&field2=0&field4=1&field6=3&field7=2&field8=8&field9=9&field12=", "Submit string was correct.");
is(frames['submit_frame'].location.href, "http://localhost:8888/blah?field1=teststring&field2=0&field4=1&field6=3&field7=2&field8=8&field9=9&field12=", "Submit string was correct.");
SimpleTest.finish();
}
</script>

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

@ -57,7 +57,7 @@
SimpleTest.waitForExplicitFinish();
function doCheck(){
is(frames['submit_frame'].location.href, "http://mochi.test:8888/blah?field1-2=teststring&field2-2=0&field4-2=1&field6-2=3&field7-2=2&field8-2=8&field9-2=9&field12-2=&field1=teststring&field2=0&field4=1&field6=3&field7=2&field8=8&field9=9&field12=&field14=14&field14-2=14", "Submit string was correct.");
is(frames['submit_frame'].location.href, "http://localhost:8888/blah?field1-2=teststring&field2-2=0&field4-2=1&field6-2=3&field7-2=2&field8-2=8&field9-2=9&field12-2=&field1=teststring&field2=0&field4=1&field6=3&field7=2&field8=8&field9=9&field12=&field14=14&field14-2=14", "Submit string was correct.");
SimpleTest.finish();
}
</script>

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

@ -22,7 +22,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=392567
/** Test for Bug 392567 **/
var dataUrl = "http://mochi.test:8888/tests/content/html/content/test/bug392567.jar";
var dataUrl = "http://localhost:8888/tests/content/html/content/test/bug392567.jar";
var jarUrl = "jar:" + dataUrl + "!/index.html";
var httpUrl = location.href.replace(/\.html.*/, "_404");

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

@ -2,11 +2,11 @@
<script>
function checkDomain(str, msg) {
window.parent.postMessage((str == document.domain) + ";" +msg,
"http://mochi.test:8888");
"http://localhost:8888/");
}
function reportException(msg) {
window.parent.postMessage(false + ";" + msg, "http://mochi.test:8888");
window.parent.postMessage(false + ";" + msg, "http://localhost:8888/");
}
var win1;

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

@ -18,7 +18,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=445004
<script type="application/javascript">
/** Test for Bug 445004 **/
is(window.location.hostname, "mochi.test", "Unexpected hostname");
is(window.location.hostname, "localhost", "Unexpected hostname");
is(window.location.port, "8888", "Unexpected port; fix testcase");
SimpleTest.waitForExplicitFinish();

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

@ -5,7 +5,7 @@ function handleRequest(request, response)
var key = request.queryString.match(/^key=(.*)$/);
if (getState(key[1]) == "redirect") {
var origin = request.host == "mochi.test" ? "example.org" : "mochi.test:8888";
var origin = request.host == "localhost" ? "example.org" : "localhost:8888";
response.setStatusLine(request.httpVersion, 303, "See Other");
response.setHeader("Location", "http://" + origin + "/tests/content/media/test/seek.ogv");
response.setHeader("Content-Type", "text/html");

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

@ -77,7 +77,7 @@ function createVideo(id) {
v.addEventListener(t, listener, false);
}
}
v.src = "http://mochi.test:8888/tests/content/media/test/320x240.ogv";
v.src = "http://localhost:8888/tests/content/media/test/320x240.ogv";
register(v);
return v;
}

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

@ -53,7 +53,7 @@ var key = Math.floor(Math.random()*100000000);
// In v1, try loading from same-origin first and then getting redirected to
// another origin.
v1.src = "http://mochi.test:8888/tests/content/media/test/dynamic_redirect.sjs?key=v1_" + key;
v1.src = "http://localhost:8888/tests/content/media/test/dynamic_redirect.sjs?key=v1_" + key;
v1.load();
// In v2, try loading cross-origin first and then getting redirected to

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

@ -17,9 +17,9 @@
<script>
onload = function() {
nodes = document.getAnonymousNodes(document.getElementById('div1'));
parent.postMessage(nodes ? nodes.length : 0, "http://mochi.test:8888");
parent.postMessage(nodes ? nodes.length : 0, "http://localhost:8888");
nodes = document.getAnonymousNodes(document.getElementById('div2'));
parent.postMessage(nodes ? nodes.length : 0, "http://mochi.test:8888");
parent.postMessage(nodes ? nodes.length : 0, "http://localhost:8888");
}
</script>
</html>

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

@ -12,7 +12,7 @@
<script>
onload = function() {
nodes = document.getAnonymousNodes(document.getElementById('d'));
parent.postMessage(nodes ? nodes.length : 0, "http://mochi.test:8888");
parent.postMessage(nodes ? nodes.length : 0, "http://localhost:8888");
}
</script>
</html>

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

@ -29,7 +29,7 @@ var messages = 0;
function receiveMessage(e)
{
is(e.origin, "http://mochi.test:8888", "wrong sender!");
is(e.origin, "http://localhost:8888", "wrong sender!");
messages++;
gen.send(e.data);
}

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

@ -52,7 +52,7 @@
}
const text="MOZILLA";
const nostoreURI = "http://mochi.test:8888/tests/docshell/test/chrome/" +
const nostoreURI = "http://localhost:8888/tests/docshell/test/chrome/" +
"215405_nostore.html";
const nocacheURI = "https://example.com:443/tests/docshell/test/chrome/" +
"215405_nocache.html";

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

@ -118,7 +118,7 @@
function testsIterator() {
// Load a page with a no-cache header, followed by a simple page
// On pagehide, first page should report it is not being persisted
var test1DocURI = "http://mochi.test:8888/tests/docshell/test/chrome/92598_nostore.html";
var test1DocURI = "http://localhost:8888/tests/docshell/test/chrome/92598_nostore.html";
gExpected = [{type: "pagehide", persisted: true},
{type: "load", title: "test1"},

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

@ -410,7 +410,7 @@ function enableBFCache(enable) {
* directory.
*/
function getHttpUrl(filename) {
return "http://mochi.test:8888/chrome/docshell/test/chrome/" + filename;
return "http://localhost:8888/chrome/docshell/test/chrome/" + filename;
}
/**

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

@ -58,7 +58,7 @@ function loadEvent(window, callback)
function loadTestTarget(callback)
{
gTargetWindow = window.open("http://mochi.test:8888", "bug369814target");
gTargetWindow = window.open("http://localhost:8888", "bug369814target");
loadEvent(gTargetWindow, callback);
}
@ -126,37 +126,37 @@ function anchorTest(test) {
var gTests = [
{ "name" : "iframes.html loaded from non-jar type, pref disabled",
"url" : "jar:http://mochi.test:8888/tests/docshell/test/bug369814.zip!/iframes.html",
"url" : "jar:http://localhost:8888/tests/docshell/test/bug369814.zip!/iframes.html",
"pref" : false,
"pokes" : { },
"func" : loadErrorTest,
},
{ "name" : "refresh.html loaded from non-jar type, pref enabled",
"url" : "jar:http://mochi.test:8888/tests/docshell/test/bug369814.zip!/refresh.html",
"url" : "jar:http://localhost:8888/tests/docshell/test/bug369814.zip!/refresh.html",
"pref" : true,
"pokes" : { },
"func" : refreshTest,
},
{ "name" : "iframes.html loaded from non-jar type, pref enabled",
"url" : "jar:http://mochi.test:8888/tests/docshell/test/bug369814.zip!/iframes.html",
"url" : "jar:http://localhost:8888/tests/docshell/test/bug369814.zip!/iframes.html",
"pref" : true,
"pokes" : { },
"func" : iframeTest,
},
{ "name" : "anchors.html loaded from non-jar type, pref enabled",
"url" : "jar:http://mochi.test:8888/tests/docshell/test/bug369814.zip!/anchors.html",
"url" : "jar:http://localhost:8888/tests/docshell/test/bug369814.zip!/anchors.html",
"pref" : true,
"pokes" : { },
"func" : anchorTest,
},
{ "name" : "iframes.html loaded from view-source jar type, pref disabled",
"url" : "jar:view-source:http://mochi.test:8888/tests/docshell/test/bug369814.jar!/iframes.html",
"url" : "jar:view-source:http://localhost:8888/tests/docshell/test/bug369814.jar!/iframes.html",
"pref" : false,
"pokes" : { },
"func" : loadErrorTest
},
{ "name" : "iframes.html loaded from view-source jar type, pref enabled",
"url" : "jar:view-source:http://mochi.test:8888/tests/docshell/test/bug369814.jar!/iframes.html",
"url" : "jar:view-source:http://localhost:8888/tests/docshell/test/bug369814.jar!/iframes.html",
"pref" : true,
"pokes" : { },
"func" : loadErrorTest

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

@ -10,7 +10,7 @@
SimpleTest.waitForExplicitFinish();
var workingURL = "http://mochi.test:8888/tests/docshell/test/bug529119-window.html";
var workingURL = "http://localhost:8888/tests/docshell/test/bug529119-window.html";
var faultyURL = "http://some-non-existent-domain-27489274c892748217cn2384.com/";
var w = null;

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

@ -10,7 +10,7 @@
SimpleTest.waitForExplicitFinish();
var workingURL = "http://mochi.test:8888/tests/docshell/test/bug529119-window.html";
var workingURL = "http://localhost:8888/tests/docshell/test/bug529119-window.html";
var faultyURL = "http://some-non-existent-domain-27489274c892748217cn2384.com/";
var w = null;

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

@ -23,7 +23,7 @@ not get added to global history.
SimpleTest.waitForExplicitFinish();
var startURI = "http://mochi.test:8888/tests/docshell/test/bug94514-postpage.html";
var startURI = "http://localhost:8888/tests/docshell/test/bug94514-postpage.html";
var postedURI = startURI + "?posted=1";
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");

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

@ -1,7 +1,7 @@
CACHE MANIFEST
http://mochi.test:8888/tests/SimpleTest/SimpleTest.js
http://mochi.test:8888/MochiKit/packed.js
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
http://localhost:8888/tests/SimpleTest/SimpleTest.js
http://localhost:8888/MochiKit/packed.js
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
test_bug445544.html
445544_part1.html

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

@ -1,4 +1,4 @@
# This doesn't start with the magic cache manifest line.
http://mochi.test:8888/tests/SimpleTest/SimpleTest.js
http://mochi.test:8888/MochiKit/packed.js
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
http://localhost:8888/tests/SimpleTest/SimpleTest.js
http://localhost:8888/MochiKit/packed.js
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js

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

@ -1,7 +1,7 @@
CACHE MANIFEST
http://mochi.test:8888/tests/SimpleTest/SimpleTest.js
http://mochi.test:8888/MochiKit/packed.js
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
http://localhost:8888/tests/SimpleTest/SimpleTest.js
http://localhost:8888/MochiKit/packed.js
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
FALLBACK:
namespace1/ fallback.html

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.cacheManifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.cacheManifest">
<head>
<title>Foreign page 2</title>
@ -15,13 +15,13 @@ function manifestUpdated()
.getService(Components.interfaces.nsIApplicationCacheService);
var foreign2cache = appCacheService.chooseApplicationCache(
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html");
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html");
OfflineTest.ok(foreign2cache, "Foreign 2 cache present, chosen for foreign2.html");
OfflineTest.is(foreign2cache.groupID, "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.cacheManifest")
OfflineTest.is(foreign2cache.groupID, "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.cacheManifest")
var foreign1cache = appCacheService.getActiveCache(
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest");
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest");
OfflineTest.ok(foreign1cache, "Foreign 1 cache loaded");
foreign1cache.discard();
@ -35,15 +35,15 @@ function onLoaded()
.getService(Components.interfaces.nsIApplicationCacheService);
var foreign1cache = appCacheService.getActiveCache(
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest");
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest");
OfflineTest.ok(foreign1cache, "Foreign 1 cache loaded");
var foreign2cache = appCacheService.getActiveCache(
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.cacheManifest");
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.cacheManifest");
OfflineTest.ok(!foreign2cache, "Foreign 2 cache not present");
foreign1cache = appCacheService.chooseApplicationCache(
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html");
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html");
OfflineTest.ok(!foreign1cache, "foreign2.html not chosen from foreign1 cache");
try

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

@ -1,6 +1,6 @@
function handleRequest(request, response)
{
response.setStatusLine(request.httpVersion, 307, "Moved temporarly");
response.setHeader("Location", "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/updating.cacheManifest");
response.setHeader("Location", "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/updating.cacheManifest");
response.setHeader("Content-Type", "text/cache-manifest");
}

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

@ -1,7 +1,7 @@
CACHE MANIFEST
http://mochi.test:8888/tests/SimpleTest/SimpleTest.js
http://mochi.test:8888/MochiKit/packed.js
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
http://localhost:8888/tests/SimpleTest/SimpleTest.js
http://localhost:8888/MochiKit/packed.js
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
# The following item doesn't exist, and will cause an update error.
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/doesntExist.html
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/doesntExist.html

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

@ -50,7 +50,7 @@ applicationCache.oncached = function() {
// Make the obsoleting.sjs return 404 NOT FOUND code
var req = new XMLHttpRequest();
req.open("GET", "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/obsoletingManifest.sjs?state=");
req.open("GET", "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/obsoletingManifest.sjs?state=");
var channel = req.channel
.QueryInterface(Components.interfaces.nsIApplicationCacheChannel);
channel.chooseApplicationCache = false;

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

@ -1,9 +1,9 @@
CACHE MANIFEST
CACHE:
http://mochi.test:8888/tests/SimpleTest/SimpleTest.js
http://mochi.test:8888/MochiKit/packed.js
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
http://localhost:8888/tests/SimpleTest/SimpleTest.js
http://localhost:8888/MochiKit/packed.js
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
NETWORK:
bogus/specific/

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

@ -2,28 +2,28 @@ ver1manifest =
"CACHE MANIFEST\n" +
"# v1\n" +
"\n" +
"http://mochi.test:8888/tests/SimpleTest/SimpleTest.js\n" +
"http://mochi.test:8888/MochiKit/packed.js\n" +
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js\n" +
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/explicitRedirect.sjs";
"http://localhost:8888/tests/SimpleTest/SimpleTest.js\n" +
"http://localhost:8888/MochiKit/packed.js\n" +
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js\n" +
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/explicitRedirect.sjs";
ver2manifest =
"CACHE MANIFEST\n" +
"# v2\n" +
"\n" +
"http://mochi.test:8888/tests/SimpleTest/SimpleTest.js\n" +
"http://mochi.test:8888/MochiKit/packed.js\n" +
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js\n" +
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/explicitRedirect.sjs";
"http://localhost:8888/tests/SimpleTest/SimpleTest.js\n" +
"http://localhost:8888/MochiKit/packed.js\n" +
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js\n" +
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/explicitRedirect.sjs";
ver3manifest =
"CACHE MANIFEST\n" +
"# v3\n" +
"\n" +
"http://mochi.test:8888/tests/SimpleTest/SimpleTest.js\n" +
"http://mochi.test:8888/MochiKit/packed.js\n" +
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js\n" +
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/explicitRedirect.sjs";
"http://localhost:8888/tests/SimpleTest/SimpleTest.js\n" +
"http://localhost:8888/MochiKit/packed.js\n" +
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js\n" +
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/explicitRedirect.sjs";
function handleRequest(request, response)
{

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

@ -1,11 +1,11 @@
CACHE MANIFEST
http://mochi.test:8888/tests/SimpleTest/SimpleTest.js
http://mochi.test:8888/MochiKit/packed.js
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
http://localhost:8888/tests/SimpleTest/SimpleTest.js
http://localhost:8888/MochiKit/packed.js
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
# The following item doesn't have the same scheme as the manifest, and
# will be ignored.
https://mochi.test:8888/MochiKit/packed.js
https://localhost:8888/MochiKit/packed.js
# The following item is not a valid URI and will be ignored
bad:/uri/invalid

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

@ -1,12 +1,12 @@
CACHE MANIFEST
http://mochi.test:8888/tests/SimpleTest/SimpleTest.js
http://mochi.test:8888/MochiKit/packed.js
http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
http://localhost:8888/tests/SimpleTest/SimpleTest.js
http://localhost:8888/MochiKit/packed.js
http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js
# The following item doesn't have the same scheme as the manifest, and
# will be ignored.
https://mochi.test:8888/MochiKit/packed.js
https://localhost:8888/MochiKit/packed.js
# The following item is not a valid URI and will be ignored
bad:/uri/invalid

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/badManifestMagic.cacheManifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/badManifestMagic.cacheManifest">
<head>
<title>bad manifest magic</title>
@ -17,9 +17,9 @@ function handleError() {
// These items are listed in the manifest, but the error should have
// prevented them from being committed to the cache.
OfflineTest.checkCache("http://mochi.test:8888/tests/SimpleTest/SimpleTest.js", false);
OfflineTest.checkCache("http://mochi.test:8888/MochiKit/packed.js", false);
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", false);
OfflineTest.checkCache("http://localhost:8888/tests/SimpleTest/SimpleTest.js", false);
OfflineTest.checkCache("http://localhost:8888/MochiKit/packed.js", false);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", false);
OfflineTest.teardown();
OfflineTest.finish();

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.notmanifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.notmanifest">
<head>
<title>bad manifest content type</title>
@ -17,9 +17,9 @@ function handleError() {
// These items are listed in the manifest, but the error should have
// prevented them from being committed to the cache.
OfflineTest.checkCache("http://mochi.test:8888/tests/SimpleTest/SimpleTest.js", false);
OfflineTest.checkCache("http://mochi.test:8888/MochiKit/packed.js", false);
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", false);
OfflineTest.checkCache("http://localhost:8888/tests/SimpleTest/SimpleTest.js", false);
OfflineTest.checkCache("http://localhost:8888/MochiKit/packed.js", false);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", false);
OfflineTest.teardown();
OfflineTest.finish();

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest">
<head>
<title>Bug 460353</title>
@ -81,8 +81,8 @@ function finish()
.newURI(window.location.href, null, null);
pm.remove(uri.host, "offline-app");
cleanCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest");
cleanCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/updatingManifest.sjs");
cleanCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest");
cleanCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/updatingManifest.sjs");
SimpleTest.finish();
}

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/fallback.cacheManifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/fallback.cacheManifest">
<head>
<title>Fallback on different origin redirect test</title>
@ -8,9 +8,10 @@
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
<script class="testbody" type="text/javascript">
function manifestUpdated()
{
fallbackFrame.location = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/redirectToDifferentOrigin.sjs";
fallbackFrame.location = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/redirectToDifferentOrigin.sjs";
// Invokes load of fallback.html
}

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/changingManifest.sjs">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/changingManifest.sjs">
<head>
<title>changing manifest test</title>
@ -12,8 +12,8 @@
var gGotChecking = false;
var gGotDownloading = false;
var g1SecUrl = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/changing1Sec.sjs";
var g1HourUrl = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/changing1Hour.sjs";
var g1SecUrl = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/changing1Sec.sjs";
var g1HourUrl = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/changing1Hour.sjs";
var gCacheContents = null;

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/fallback.cacheManifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/fallback.cacheManifest">
<head>
<title>Fallback entry test</title>
@ -26,7 +26,7 @@ var gCompleteTimeout = null;
function manifestUpdated()
{
gManifestUpdated = true;
fallbackFrame.location = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html";
fallbackFrame.location = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html";
// Invokes load of fallback.html
}
@ -42,7 +42,7 @@ function onFallbackLoad(fallbackIdentification)
case 101:
OfflineTest.is(fallbackIdentification, 1, "fallback for namespace1/ in step " + gStep);
fallbackFrame.location = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub-non-existing.html";
fallbackFrame.location = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub-non-existing.html";
// Invokes load of fallback.html
break;
@ -50,7 +50,7 @@ function onFallbackLoad(fallbackIdentification)
case 102:
OfflineTest.is(fallbackIdentification, 1, "fallback for namespace1/, sub namespace in name of the frame in step " + gStep);
fallbackFrame.location = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub/non-existing.html";
fallbackFrame.location = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub/non-existing.html";
// Invokes load of fallback2.html
break;
@ -58,7 +58,7 @@ function onFallbackLoad(fallbackIdentification)
case 103:
OfflineTest.is(fallbackIdentification, 2, "fallback for namespace1/sub/ in step " + gStep);
fallbackFrame.location = "HTTP://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub/non-existing.html";
fallbackFrame.location = "HTTP://LOCALHOST:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub/non-existing.html";
// Invokes load of fallback2.html
break;
@ -73,7 +73,7 @@ function onFallbackLoad(fallbackIdentification)
finalize();
}, 3000);
gTopWindow = window.open("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace2/non-existing.html");
gTopWindow = window.open("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace2/non-existing.html");
// Invokes load of fallbackTop.html
break;
@ -82,7 +82,7 @@ function onFallbackLoad(fallbackIdentification)
// Try all over again. This checks there are no entries for non-existing
// pages created/leaked. That would prevent fallback load.
gStep = 100;
fallbackFrame.location = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html";
fallbackFrame.location = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html";
// Invokes load of fallback1.html, again, from the start
// no break
@ -108,10 +108,10 @@ function finalize()
{
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub-non-existing.html", false);
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub/non-existing.html", false);
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html", false);
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace2/non-existing.html", false);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub-non-existing.html", false);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/sub/non-existing.html", false);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html", false);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace2/non-existing.html", false);
OfflineTest.teardown();
OfflineTest.finish();
@ -130,6 +130,6 @@ if (OfflineTest.setup()) {
</head>
<body>
<iframe name="fallbackFrame" src="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html"></iframe>
<iframe name="fallbackFrame" src="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/namespace1/non-existing.html"></iframe>
</body>
</html>

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest">
<head>
<title>Foreign test</title>
@ -26,12 +26,12 @@ function manifestUpdated()
.getService(Components.interfaces.nsIApplicationCacheService);
foreign1cache = appCacheService.chooseApplicationCache(
"http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html");
"http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html");
OfflineTest.ok(foreign1cache, "foreign2.html chosen from foreign1 cache");
OfflineTest.is(foreign1cache.groupID, "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest")
OfflineTest.is(foreign1cache.groupID, "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign1.cacheManifest")
window.location = "http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html";
window.location = "http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/foreign2.html";
}
SimpleTest.waitForExplicitFinish();

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

@ -1,4 +1,4 @@
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest">
<html xmlns="http://www.w3.org/1999/xhtml" manifest="http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest">
<head>
<title>identical manifest test</title>
@ -20,9 +20,9 @@ function noUpdate()
// The document that requested the manifest should be in the cache
OfflineTest.checkCache(window.location.href, true);
OfflineTest.checkCache("http://mochi.test:8888/tests/SimpleTest/SimpleTest.js", true);
OfflineTest.checkCache("http://mochi.test:8888/MochiKit/packed.js", true);
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", true);
OfflineTest.checkCache("http://localhost:8888/tests/SimpleTest/SimpleTest.js", true);
OfflineTest.checkCache("http://localhost:8888/MochiKit/packed.js", true);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", true);
OfflineTest.teardown();
@ -35,18 +35,18 @@ function manifestUpdated()
OfflineTest.ok(gGotDownloading, "Should get a downloading event");
// The manifest itself should be in the cache
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest", true);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/simpleManifest.cacheManifest", true);
// The document that requested the manifest should be in the cache
OfflineTest.checkCache(window.location.href, true);
// The entries from the manifest should be in the cache
OfflineTest.checkCache("http://mochi.test:8888/tests/SimpleTest/SimpleTest.js", true);
OfflineTest.checkCache("http://mochi.test:8888/MochiKit/packed.js", true);
OfflineTest.checkCache("http://mochi.test:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", true);
OfflineTest.checkCache("http://localhost:8888/tests/SimpleTest/SimpleTest.js", true);
OfflineTest.checkCache("http://localhost:8888/MochiKit/packed.js", true);
OfflineTest.checkCache("http://localhost:8888/tests/dom/tests/mochitest/ajax/offline/offlineTests.js", true);
// The bad entries from the manifest should not be in the cache
OfflineTest.checkCache("https://mochi.test:8888/MochiKit/packed.js", false);
OfflineTest.checkCache("https://localhost:8888/MochiKit/packed.js", false);
OfflineTest.checkCache("bad:/uri/invalid", false);
// Now make sure applicationCache.update() does what we expect.

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше