gecko-dev/layout/tools
Timothy Nikkel c6fc2ec62c Bug 1593171. Protect against the same test from calling RecordResult more than once in the reftest harness. r=mattwoodrow
Some crashtests call window.location.reload one or more times. Each time the test document loads we call OnDocumentLoad, and each call of that function can lead to a RecordResult call, either directly or indirectly through WaitForTestEnd and its MakeProgress state machine.

Although the error when this happens ("program error managing timeouts") is confusing I found a couple intermittent instances of this happening in our bugzilla.

However with the fission changes to the reftest harness (which in general make things more async) this is much more common because we keep the tests alive longer before tearing down the test page, giving it more of a chance to happen.

To fix it we pass around the top level test url so it can make its way to RecordResult. This means we can ignore RecordResult calls for previous tests, and ignore the second or more RecordResult call for the current test. We reset the count when we start a new test.

Differential Revision: https://phabricator.services.mozilla.com/D51342

--HG--
extra : moz-landing-system : lando
2019-11-04 19:48:58 +00:00
..
layout-debug Bug 1590185 Part 3 - Add --paged command line argument to layout debugger. r=heycam 2019-10-29 19:51:44 +00:00
recording Bug 1561435 - Format layout/, a=automatic-formatting 2019-07-05 10:50:41 +02:00
reftest Bug 1593171. Protect against the same test from calling RecordResult more than once in the reftest harness. r=mattwoodrow 2019-11-04 19:48:58 +00:00
tests