зеркало из https://github.com/mozilla/gecko-dev.git
Bug 543634, fix intermittent orange in template test by waiting until data is loaded before adding expected error messages
This commit is contained in:
Родитель
a689d5bcc3
Коммит
16dc90226c
|
@ -52,6 +52,7 @@ const XUL_NS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
|
|||
const debug = false;
|
||||
|
||||
var expectedConsoleMessages = [];
|
||||
var expectLoggedMessages = null;
|
||||
|
||||
try {
|
||||
const RDF = Components.classes["@mozilla.org/rdf/rdf-service;1"].
|
||||
|
@ -88,6 +89,9 @@ function test_template()
|
|||
if (needsOpen)
|
||||
root.open = true;
|
||||
|
||||
if (expectLoggedMessages)
|
||||
expectLoggedMessages();
|
||||
|
||||
checkResults(root, 0);
|
||||
|
||||
if (changes.length) {
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
-->
|
||||
|
||||
<window title="XUL Template Tests" width="500" height="600"
|
||||
onload="expectLoggedMessages(); test_template();"
|
||||
onload="test_template();"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
<script type="application/javascript"
|
||||
src="chrome://mochikit/content/MochiKit/packed.js"></script>
|
||||
|
@ -37,7 +37,7 @@ var expectedOutput =
|
|||
Components.classes["@mozilla.org/consoleservice;1"].
|
||||
getService(Components.interfaces.nsIConsoleService).reset();
|
||||
|
||||
function expectLoggedMessages()
|
||||
expectLoggedMessages = function()
|
||||
{
|
||||
// check log to ensure that two rows have been added
|
||||
var initialNumber = Number(document.getElementById("root").firstChild.nextSibling.id.substring(3));
|
||||
|
|
Загрузка…
Ссылка в новой задаче