зеркало из https://github.com/mozilla/gecko-dev.git
backing out 5ee85f7 due to test harness failures
This commit is contained in:
Родитель
44267422bf
Коммит
f1e889e9d4
|
@ -514,10 +514,6 @@ function testListing(metadata, response)
|
||||||
true);
|
true);
|
||||||
dumpn("count: " + count);
|
dumpn("count: " + count);
|
||||||
var tests = jsonArrayOfTestFiles(links);
|
var tests = jsonArrayOfTestFiles(links);
|
||||||
var runtests = "Run Tests";
|
|
||||||
if (metadata.queryString.indexOf("autorun=1") != -1) {
|
|
||||||
runtests = "Stop Tests";
|
|
||||||
}
|
|
||||||
response.write(
|
response.write(
|
||||||
HTML(
|
HTML(
|
||||||
HEAD(
|
HEAD(
|
||||||
|
@ -540,7 +536,7 @@ function testListing(metadata, response)
|
||||||
),
|
),
|
||||||
BODY(
|
BODY(
|
||||||
DIV({class: "container"},
|
DIV({class: "container"},
|
||||||
H2("--> ", A({href: "#", id: "runtests"}, runtests), " <--"),
|
H2("--> ", A({href: "#", id: "runtests"}, "Run Tests"), " <--"),
|
||||||
P({style: "float: right;"},
|
P({style: "float: right;"},
|
||||||
SMALL(
|
SMALL(
|
||||||
"Based on the ",
|
"Based on the ",
|
||||||
|
@ -550,8 +546,6 @@ function testListing(metadata, response)
|
||||||
),
|
),
|
||||||
DIV({class: "status"},
|
DIV({class: "status"},
|
||||||
H1({id: "indicator"}, "Status"),
|
H1({id: "indicator"}, "Status"),
|
||||||
H2({id: "file"}, "File: ",
|
|
||||||
SPAN({id: "progress"}, "0 / " + count + " (0%)")),
|
|
||||||
H2({id: "pass"}, "Passed: ", SPAN({id: "pass-count"},"0")),
|
H2({id: "pass"}, "Passed: ", SPAN({id: "pass-count"},"0")),
|
||||||
H2({id: "fail"}, "Failed: ", SPAN({id: "fail-count"},"0")),
|
H2({id: "fail"}, "Failed: ", SPAN({id: "fail-count"},"0")),
|
||||||
H2({id: "fail"}, "Todo: ", SPAN({id: "todo-count"},"0"))
|
H2({id: "fail"}, "Todo: ", SPAN({id: "todo-count"},"0"))
|
||||||
|
|
|
@ -91,7 +91,7 @@ div#current-test {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#pass, #fail, #file {
|
#pass, #fail {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: .5em;
|
padding: .5em;
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,7 +11,6 @@ TestRunner.logEnabled = false;
|
||||||
TestRunner._currentTest = 0;
|
TestRunner._currentTest = 0;
|
||||||
TestRunner.currentTestURL = "";
|
TestRunner.currentTestURL = "";
|
||||||
TestRunner._urls = [];
|
TestRunner._urls = [];
|
||||||
TestRunner._title = "";
|
|
||||||
|
|
||||||
TestRunner.timeout = 5 * 60 * 1000; // 5 minutes.
|
TestRunner.timeout = 5 * 60 * 1000; // 5 minutes.
|
||||||
TestRunner.maxTimeouts = 4; // halt testing after too many timeouts
|
TestRunner.maxTimeouts = 4; // halt testing after too many timeouts
|
||||||
|
@ -96,7 +95,7 @@ TestRunner._makeIframe = function (url, retry) {
|
||||||
TestRunner.logger.log("Error: Unable to restore focus, expect failures and timeouts.");
|
TestRunner.logger.log("Error: Unable to restore focus, expect failures and timeouts.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
window.scrollTo(0, 0);
|
window.scrollTo(0, $('indicator').offsetTop);
|
||||||
iframe.src = url;
|
iframe.src = url;
|
||||||
iframe.name = url;
|
iframe.name = url;
|
||||||
iframe.width = "500";
|
iframe.width = "500";
|
||||||
|
@ -113,7 +112,6 @@ TestRunner.runTests = function (/*url...*/) {
|
||||||
if (TestRunner.logEnabled)
|
if (TestRunner.logEnabled)
|
||||||
TestRunner.logger.log("SimpleTest START");
|
TestRunner.logger.log("SimpleTest START");
|
||||||
|
|
||||||
TestRunner._title = document.title;
|
|
||||||
TestRunner._urls = flattenArguments(arguments);
|
TestRunner._urls = flattenArguments(arguments);
|
||||||
$('testframe').src="";
|
$('testframe').src="";
|
||||||
TestRunner._checkForHangs();
|
TestRunner._checkForHangs();
|
||||||
|
@ -171,12 +169,6 @@ TestRunner.runNextTest = function() {
|
||||||
if (TestRunner.onComplete)
|
if (TestRunner.onComplete)
|
||||||
TestRunner.onComplete();
|
TestRunner.onComplete();
|
||||||
}
|
}
|
||||||
var cur = TestRunner._currentTest;
|
|
||||||
var total = TestRunner._urls.length;
|
|
||||||
var progress = cur + " / " + total + " (" +
|
|
||||||
Math.floor(100 * (cur / total)) + "%)";
|
|
||||||
document.title = progress + " - " + TestRunner._title;
|
|
||||||
$("progress").innerHTML = progress;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -138,16 +138,11 @@ RunSet.runall = function(e) {
|
||||||
}
|
}
|
||||||
RunSet.reloadAndRunAll = function(e) {
|
RunSet.reloadAndRunAll = function(e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
//window.location.hash = "";
|
||||||
var addParam = "";
|
var addParam = "";
|
||||||
if (params.autorun) {
|
if (params.autorun) {
|
||||||
if (!TestRunner._haltTests) {
|
window.location.search += "";
|
||||||
TestRunner._haltTests = true;
|
window.location.href = window.location.href;
|
||||||
$('runtests').innerHTML = "Restart Tests";
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
// already clicked stop, so just reload
|
|
||||||
window.location.href = window.location.href;
|
|
||||||
}
|
|
||||||
} else if (window.location.search) {
|
} else if (window.location.search) {
|
||||||
window.location.href += "&autorun=1";
|
window.location.href += "&autorun=1";
|
||||||
} else {
|
} else {
|
||||||
|
|
Загрузка…
Ссылка в новой задаче