mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-25 19:25:43 +00:00
795728d89d
This accomplishes three things: 1) Easier to use CLI when running without the benefit of testing/mochitest/mach_commands.py 2) Guarantees these arguments are mutually exclusive 3) Simplifies a bunch of logic in the test harness The primary motivation for this change is to slightly improve the UX when running mochitest from a taskcluster interactive loaner. However, this is more of a bandaid solution that was easy to implement before the proper fix in bug 1293259 can be landed. MozReview-Commit-ID: IeHBGrJ0Sji --HG-- extra : rebase_source : ba1b7e437881e363fe0051dccd3d732221311c59
41 lines
1012 B
HTML
41 lines
1012 B
HTML
<html>
|
|
<head>
|
|
<title>redirecting...</title>
|
|
|
|
<script type="text/javascript">
|
|
function redirect(aURL)
|
|
{
|
|
// We create a listener for this event in browser-test.js which will
|
|
// get picked up when specifying --flavor=chrome or --flavor=a11y
|
|
var event = new CustomEvent("contentEvent", {
|
|
bubbles: true,
|
|
detail: {
|
|
"data": aURL + location.search,
|
|
"type": "loadURI"
|
|
}
|
|
});
|
|
document.dispatchEvent(event);
|
|
}
|
|
|
|
function redirectToHarness()
|
|
{
|
|
redirect("chrome://mochikit/content/harness.xul");
|
|
}
|
|
|
|
function onLoad() {
|
|
// Wait for MozAfterPaint, since the listener in browser-test.js is not
|
|
// added until then.
|
|
window.addEventListener("MozAfterPaint", function testOnMozAfterPaint() {
|
|
window.removeEventListener("MozAfterPaint", testOnMozAfterPaint);
|
|
setTimeout(redirectToHarness, 0);
|
|
});
|
|
|
|
}
|
|
</script>
|
|
</head>
|
|
|
|
<body onload="onLoad();">
|
|
redirecting...
|
|
</body>
|
|
</html>
|