TEST-UNEXPECTED-FAIL | comm/mail/base/test/unit/test_windows_font_migration.js | xpcshell return code: 0
Categories
(Thunderbird :: General, defect)
Tracking
(Not tracked)
People
(Reporter: jorgk-bmo, Assigned: jorgk-bmo)
Details
(Whiteboard: [Thunderbird-testfailure: X Windows])
Attachments
(1 file)
8.09 KB,
patch
|
aceman
:
review+
|
Details | Diff | Splinter Review |
TEST-UNEXPECTED-FAIL | comm/mail/base/test/unit/test_windows_font_migration.js | xpcshell return code: 0
EDIT: Wrong range, see comment #2.
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=ea09774456976ada64ed753a00724ef6bc&tochange=92d1c344e7c53af9b8ad8a4192d93478f7
Hmm, something changed with Windows fonts, I can't see it right now. I'll have to check it out locally. BTW, this test only runs on Windows:
https://searchfox.org/comm-central/rev/9bc5aee7e03b167f154af5011a9f6ab286ad7bf0/mail/base/test/unit/xpcshell.ini#18
Assignee | ||
Comment 1•5 years ago
|
||
Very strange, test fails with:
0:01.02 ERROR NS_ERROR_UNEXPECTED: Component returned failure code: 0x8000ffff (NS_ERROR_UNEXPECTED) [nsIPrefBranch.getIntPref]
and debug shows that it got font.size.variable.x-unicode
successfully and fails on font.size.fixed.x-unicode
.
The test passes if I remove these two lines:
// Assert.equal(Services.prefs.getIntPref("font.size.fixed." + aEncoding),
// expectedFonts.fixedSize);
Weird.
Assignee | ||
Comment 2•5 years ago
|
||
Wrong regression range, that was already present earlier:https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=e8b3c73b4e328be88aa90f31e1fa9772b5&tochange=ea09774456976ada64ed753a00724ef6bc
So it looks like
Bug 1537575 - Cleanup generic font-family handling. r=jfkthame
Emilio, where did that preference get lost?
Comment 3•5 years ago
|
||
Actually, it's https://hg.mozilla.org/mozilla-central/rev/663c37508e2f. s/fixed/monospace on the test should do.
Assignee | ||
Comment 4•5 years ago
|
||
Great, thanks. Well, I got the right person to talk to :-)
Assignee | ||
Comment 5•5 years ago
|
||
That needed to hit all 13 occurrences in the entire tree.
Comment on attachment 9055318 [details] [diff] [review] 1541139-monospace.patch Review of attachment 9055318 [details] [diff] [review]: ----------------------------------------------------------------- So what about users that have that pref modified? Do we need migration code for them? Or will it somehow happen automatically?
Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/7bfb148ee3d1
Port bug 1537594: s/font.size.fixed./font.size.monospace./ in C-C. rs=bustage-fix
Assignee | ||
Comment 8•5 years ago
|
||
OK, I landed that now. I hit font.size.fixed.
in the entire tree, 13 occurrences. The one in MailMigrator.jsm was necessary to get the test to pass.
Emilio, can you please look at the patch? As Aceman pointed out, what happens if people have changed the prefs?
I tested it and now TB just uses the new prefs ignoring the old ones. So this needs decision whether we want to add migration code for this (just take all the font..fixed. prefs and move them to the new name).
Assignee | ||
Comment 10•5 years ago
|
||
Not in this bug ;-)
Assignee | ||
Updated•5 years ago
|
Comment 11•5 years ago
|
||
There are two sets of prefs, font.size.monospace. and font.size.fixed., we're not migrating the prefs automatically because it's not clear which one should override which. We mostly used to use the monospace prefs, except in some cases.
I guess you could convert the fixed ones to monospace if the monospace one isn't set. Regarding the patch, there's a list where font.size.monospace appears twice. Looks ok otherwise.
Comment 12•5 years ago
|
||
(Doesn't sound like there's really too much need to migrate.)
Assignee | ||
Comment 13•5 years ago
|
||
(In reply to Emilio Cobos Álvarez (:emilio) from comment #11)
Regarding the patch, there's a list where font.size.monospace appears twice. Looks ok otherwise.
I can't see it, maybe you can point it out or the reviewer can spot it.
Comment 14•5 years ago
|
||
Comment on attachment 9055318 [details] [diff] [review] 1541139-monospace.patch Review of attachment 9055318 [details] [diff] [review]: ----------------------------------------------------------------- ::: mail/base/test/unit/test_windows_font_migration.js @@ +128,5 @@ > */ > var kPrefBranchesToClear = [ > "font.name.serif.", > "font.name.sans-serif.", > "font.name.monospace.", Here. @@ +130,5 @@ > "font.name.serif.", > "font.name.sans-serif.", > "font.name.monospace.", > "font.size.variable.", > + "font.size.monospace.", And here.
Assignee | ||
Comment 15•5 years ago
|
||
Umm, one is size, the other name?
Comment 16•5 years ago
|
||
Err, I'm blind, sorry :(
Comment 17•5 years ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #12)
(Doesn't sound like there's really too much need to migrate.)
Well, users will lose their settings. Some of them may not know how to set them back (think pre-configured installs for older people and with sight problems).
Description
•