Closed Bug 554188 Opened 10 years ago Closed 10 years ago

Packaged Unittests on 10.6 are failing tests/layout/reftests/bugs/534919-1.html


(Core :: Layout: Text and Fonts, defect, major)

Not set





(Reporter: lsblakk, Assigned: jfkthame)




(2 files)

Attached file reftest fail snippet
We're working on getting packaged unittests running on Talos platforms - and reftests are consistently failing on snowleopard machines on just this one test.
(log snippet attached)
Blocks: 548768
Jonathan, any thoughts on this? Comparing the test/reference images from the log, it looks like there's extra spacing in the test image.
Blocks: 534919
Whiteboard: [orange]
(In reply to comment #1)
> Jonathan, any thoughts on this? Comparing the test/reference images from the
> log, it looks like there's extra spacing in the test image.

Yeah - it looks like a bug in textrun setup, triggered by the font change (fallback) at the zwnj character next to the space, perhaps only in RTL runs. I don't understand why it's failing on 10.6 machines but not on 10.5, though. I'm suspicious that it is caused by a change (bug?) in Core Text behavior on Snow Leopard, but I haven't isolated exactly what's happening yet.
Can you take this bug? It's blocking running unittests on 10.6 on tinderbox.
Ok, I've assigned it to me and will try to get to the root of it. If you want to move forward in the meantime, I'd suggest marking it random-if OS X, as it seems to depend on the OS version.
Assignee: nobody → jfkthame
We can even make the "random-if" check specific to *just* 10.6 if we want -- the syntax is given in the removed line in the following (old) changeset.  The line there was for marking a test as random on OS X 10.4.

That might be a good idea if this stays open for more than a few days, so we can still catch failures on we can still catch [unexpected] failures on 10.5.
Followed up as described:

Using fails-if also means that if something else fixes this bug, we'll know.
This seems to happen because the glyph runs that we get back from Core Text on 10.6 are different from those we were getting on 10.5; in particular, trailing whitespace and invisible glyphs (such as direction overrides) at run boundaries are not always treated the same. This is confusing the code that extracts the glyphs from Core Text and stores them into our textruns.

To fix this, I think we can use the same trick we used with the old ATSUI code, adding a non-whitespace character (such as period) when we "wrap" text in directional overrides. This ensures that any trailing whitespace in the run will not be treated as trailing by Core Text's glyph layout process, so we get consistent behavior.
Attachment #437412 - Flags: review?(roc)
Pushed fix and re-enabled the reftest:
Closed: 10 years ago
Resolution: --- → FIXED
No longer blocks: 548768
You need to log in before you can comment on or make changes to this bug.