Closed Bug 611313 Opened 14 years ago Closed 14 years ago

Investigate why rdf template tests occasionally fail

Categories

(Core :: XUL, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: enndeakin, Assigned: enndeakin)

References

Details

Attachments

(1 file, 1 obsolete file)

The template tests occasionally fail randomly, likely due to asyncronous loading and content construction not being fully complete when the test runs. This results in the tests failing with the message such as: "incorrect child node count of vbox 0 expected 3"
The template tests are set up such that the first one uses datasources="rdf:null" to force the datasource to load blocking before the remaining tests run. However this might cause random failures in other tests if the datasource is garbage collected I guess, but I'm not sure if this can happen. This patch just uses datasources="rdf:null" on all of the template tests. We could try this to see if it improves things.
Assignee: nobody → enndeakin
Status: NEW → ASSIGNED
I don't see a bug filed on it, but locally I hit 150 ERROR TEST-UNEXPECTED-FAIL | chrome://mochitests/content/chrome/content/xul/templates/tests/chrome/test_tmpl_invalidqp.xul | correct number of logged messages - got 0, expected 1
Actually I've hit that failure on both Mac and Fedora 12 with this patch applied.
Yes, I noticed that error and working on the fix for it.
Attached patch Version 2 (deleted) — Splinter Review
Attachment #489828 - Attachment is obsolete: true
Shouldn't console messages be investigated regardless if they're expected or not? Furthermore, will expectLogMessages ever be called? It doesn't look like it, to me.
Is this likely to cover bug 611890 too?
(In reply to comment #6) > Shouldn't console messages be investigated regardless if they're expected or > not? Furthermore, will expectLogMessages ever be called? It doesn't look like > it, to me. I'm not clear which test you're referring to here. Some of the template tests are used to check for errors or messages that are logged on the console. These tests compare the messages that are output which the logging that is expected. A test can define a expectLoggedMessages function if an error is expected to generated during the test. Most error cases are handled in test_tmpl_error.xul however. Bug 611890 should be fixed by not generating additional errors.
Keywords: checkin-needed
The only use of expectLoggedMessages in the harness is > if (expectLoggedMessages) { but that doesn't actually call the function, does it?
(In reply to comment #9) > The only use of expectLoggedMessages in the harness is > > > if (expectLoggedMessages) { > > but that doesn't actually call the function, does it? It's set in some of the tests, and called about half-way through test_template() The call to expectLoggedMessages already exists; this patch doesn't add this function call if that's where your confusion is.
http://hg.mozilla.org/mozilla-central/rev/509c3d710e15 I don't know if I should mark this as fixed...
Keywords: checkin-needed
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Summary: Investigate why template tests occasionally fail → Investigate why rdf template tests occasionally fail
Component: XP Toolkit/Widgets: XUL → XUL
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: