Closed Bug 1620658 Opened 5 years ago Closed 5 years ago

windows settings-import tests (test_outlook_settings.js and test_winmail.js) are broken

Categories

(Thunderbird :: OS Integration, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 75.0

People

(Reporter: benc, Assigned: benc)

Details

Attachments

(1 file, 1 obsolete file)

This is a weird one. The tests appear to run fine, but while working on bug 1614846, test_outlook_settings.js and test_winmail.js suddenly started breaking on me.

I thought that my bug 1614846 work had broken something, but upon more investigation, it seems that the test data was bad, and that the tests should have been breaking all along!

The triggering patch in Bug 1614846 changes nsIAccountManager.accounts to return a proper JS array rather than an nsIArray.
My theory is that the tests weren't properly handling nsIArray and this was causing some checks to be skipped, thus letting the tests pass, erroneously.
Making accounts return a JS array accidentally 'fixed' the tests, so they started failing :-)

This fixes the data in the tests, but won't fix the suspected breakage in the tests themselves.
But it will prevent test fails once the first patch in Bug 1614846 is applied and the tests start running properly!

Attachment #9131532 - Flags: review?(mkmelin+mozilla)
Comment on attachment 9131532 [details] [diff] [review] 1620658-fix-windows-settings-import-tests-1.patch Review of attachment 9131532 [details] [diff] [review]: ----------------------------------------------------------------- Looks reasonable ::: mailnews/import/test/unit/test_outlook_settings.js @@ +70,4 @@ > username: "pop3user", > leaveMessagesOnServer: true, > + > + // These values are default, rather than from the Outlook settngs... typo
Attachment #9131532 - Flags: review?(mkmelin+mozilla) → review+

Tweaked to clarify the comments about default values in the testdata.

Attachment #9131532 - Attachment is obsolete: true
Attachment #9131631 - Flags: review+

win32 try build just to show the tests still passing:

https://treeherder.mozilla.org/#/jobs?repo=try-comm-central&revision=925a88e8f85f49cb168ba32f13d09f62ba4f1355

...even though they're probably really still failing without the Bug 1614846 patch!

But now they continue to work with the 1614846 patch applied: https://treeherder.mozilla.org/#/jobs?repo=try-comm-central&revision=6c81ea172348b677edd90753b6f5b5be3afbce6a

Status: NEW → ASSIGNED
Target Milestone: --- → Thunderbird 75.0

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/d1e9c855e247
Fix incorrect/missing testdata in windows settings-import tests. r=mkmelin

Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: