Closed Bug 1780576 Opened 2 years ago Closed 2 years ago

Clean up in test_ext_userScripts_register.js on failure

Categories

(WebExtensions :: General, task)

task

Tracking

(firefox104 fixed)

RESOLVED FIXED
104 Branch
Tracking Status
firefox104 --- fixed

People

(Reporter: mccr8, Assigned: mccr8)

References

Details

Attachments

(1 file)

The "equal" function in XPCShell tests apparently throws immediately on failure, which means that if it fails you get a lot of unrelated failures in this test because it then doesn't clean up after itself. I patched this by using registerCleanupFunction, and by waiting to call equal until contentPage is closed.

equal throws immediately, so if it fails you get some follow-on
failures because the test didn't clean up that make it confusing
to figure out what actually failed. This patch fixes that by using
registerCleanupFunction to remove the extension, and waits to
do the check until after contentPage has been closed.

I confirmed that there are no additional failures when this test fails with my patch.

Pushed by amccreight@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/951002217e9f
Clean up test_ext_userScripts_register.js on failure. r=extension-reviewers,mixedpuppy
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 104 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: