Last Comment Bug 851835 - Acid3 MathML: mac gets more errors than linux/windows
: Acid3 MathML: mac gets more errors than linux/windows
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: MathML (show other bugs)
: Trunk
: x86 Mac OS X
: -- normal (vote)
: ---
Assigned To: Frédéric Wang (:fredw)
:
: Anthony Jones (:kentuckyfriedtakahe, :k17e)
Mentors:
http://fred-wang.github.com/AcidTests...
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-03-16 13:25 PDT by Jonathan Steele
Modified: 2013-04-15 01:57 PDT (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments

Description Jonathan Steele 2013-03-16 13:25:39 PDT
Failed 50 tests.
    Test 08 failed: semantics size should be the one of the annotated child
    Test 09 failed: maction should have first child visible (tooltip)
    Test 10 failed: element should have the same size as child (mrow)
    Test 16 failed: bad size of lquote/rquote
    Test 18 failed: bad superscriptshift (msup)
    Test 19 failed: bad alignment (munder_center)
    Test 22 failed: bad column alignment
    Test 23 failed: bad column width
    Test 25 failed: bad rowspacing
    Test 26 failed: bad label position
    Test 27 failed: bad label spacing
    Test 28 failed: bad framespacing on the right and left
    Test 29 failed: equalcolumns not satisfied
    Test 31 failed: bad mathsize
    Test 32 failed: bad mathvariant (script)
    Test 43 failed: bad lspace/rspace
    Test 48 failed: bad lspace/rspace for minus sign (infix form)
    Test 49 failed: prefix form should be used
    Test 53 failed: bad size for mo0 (mtd)
    Test 54 failed: parenthesis should stretch symmetrically (mtd)
    Test 55 failed: bad size for stretchy operator (mtd)
    Test 57 failed: bad size for mo0 (mtd)
    Test 64 failed: bad spacing around operator 1
    Test 69 failed: bad position of inner mpadded element
    Test 73 failed: should break before the plus (auto)
    Test 74 failed: should break after the comma (auto)
    Test 75 failed: should break before the plus (newline)
    Test 76 failed: should break before the plus not after the comma (nobreak)
    Test 77 failed: should break before the plus not after the comma (badbreak & goodbreak)
    Test 78 failed: bad lineleading
    Test 79 failed: bad indentalign
    Test 80 failed: bad indentshift
    Test 81 failed: bad alignment (malignmark)
    Test 82 failed: bad alignment (groupalign)
    Test 83 failed: bad alignment (groupalign=center, malignmark)
    Test 84 failed: bad alignment (groupalign=decimalpoint, malignmark)
    Test 85 failed: bad alignment (several rows)
    Test 86 failed: bad alignment (several alignment groups in cells, mtd@groupalign)
    Test 87 failed: bad alignment (mtr@groupalign)
    Test 88 failed: bad alignment (mtable@groupalign)
    Test 89 failed: bad vertical position in mstack
    Test 90 failed: 123 should be above 456, with enough space to draw the line
    Test 91 failed: bad horizontal position (msgroup, shift)
    Test 92 failed: bad mslinethickness
    Test 93 failed: bad alignment (stackalign=left)
    Test 94 failed: bad font size in mscarries
    Test 95 failed: bad positions in mlongdiv
    Test 96 failed: bad positions in mlongdiv (longdivstyle=stackedrightright)
    Test 98 failed: mtext elements should have the width of their SVG/HTML content
    Test 99 failed: bad font size (@id99)
    Total elapsed time: 2.06s
Comment 1 Frédéric Wang (:fredw) 2013-03-16 15:13:37 PDT
The acid 3 tests uses a special Web font to determine accurate metrics of glyphs. I'm not sure if at the moment the Web font is always downloaded before the tests start, and if not that can make the tests fail. However, I expect the font to be downloaded when you arrive at test 99 and that one is very simple (it does not really involve MathML but rather CSS).

Could you clone the git repository:

https://github.com/fred-wang/AcidTestsMathML

and modify the javascript function for test 99 in AcidTestsMathML/acid3/index.html to get the values of e.g math.firstElementChild.getBoundingClientRect().width?
Comment 2 Bill Gianopoulos [:WG9s] 2013-03-17 07:26:41 PDT
I wonder if perhaps your system does not recognize the Mime Type application/font-woff.
Comment 3 Frédéric Wang (:fredw) 2013-03-22 16:26:44 PDT
I(In reply to Frédéric Wang (:fredw) from comment #1)
> The acid 3 tests uses a special Web font to determine accurate metrics of
> glyphs. I'm not sure if at the moment the Web font is always downloaded
> before the tests start

OK, I've modified the Acid3 page to verify whether the Web fonts have been downloaded before test 1. That might help you if your problem was a networking issue.
Comment 4 Bill Gianopoulos [:WG9s] 2013-03-24 12:47:18 PDT
I have included the above fixes in the version on my server at http://www.wg9s.com/mathml/acid3/

I can duplicate this issue under Linux by specifying a zoom factor.  Have you tried resetting your zoom factor to default?
Comment 5 Jonathan Steele 2013-03-24 16:39:35 PDT
(In reply to Frédéric Wang (:fredw) from comment #1)
> The acid 3 tests uses a special Web font to determine accurate metrics of
> glyphs. I'm not sure if at the moment the Web font is always downloaded
> before the tests start, and if not that can make the tests fail. However, I
> expect the font to be downloaded when you arrive at test 99 and that one is
> very simple (it does not really involve MathML but rather CSS).
> 
> Could you clone the git repository:
> 
> https://github.com/fred-wang/AcidTestsMathML
> 
> and modify the javascript function for test 99 in
> AcidTestsMathML/acid3/index.html to get the values of e.g
> math.firstElementChild.getBoundingClientRect().width?

I get 50.05000305175781
Comment 6 Frédéric Wang (:fredw) 2013-03-25 12:48:36 PDT
> I get 50.05000305175781

OK, that's near the correct 50 result although still large compared to the epsilon error value I use. Just to be sure, if you remove the "visibility: hidden;" line here

https://github.com/fred-wang/AcidTestsMathML/blob/master/acid3/index.html#L96

you should see the MathML elements. Are they displayed with the Acid3MathML fonts (black boxes and shapes) or with normal fonts (letters etc)?

I've modified a bit the tests so that the default font size should be the same for everybody and I've also relaxed a bit some conditions to allow a small error.
Comment 7 Bill Gianopoulos [:WG9s] 2013-03-25 16:03:35 PDT
(In reply to Frédéric Wang (:fredw) from comment #6)
> > I get 50.05000305175781
> 
> OK, that's near the correct 50 result although still large compared to the
> epsilon error value I use. Just to be sure, if you remove the "visibility:
> hidden;" line here
> 
> https://github.com/fred-wang/AcidTestsMathML/blob/master/acid3/index.html#L96
> 
> you should see the MathML elements. Are they displayed with the Acid3MathML
> fonts (black boxes and shapes) or with normal fonts (letters etc)?
> 
> I've modified a bit the tests so that the default font size should be the
> same for everybody and I've also relaxed a bit some conditions to allow a
> small error.

I have updated the test at http://www.wg9s.com/acid3/ to the latest.

I have also added a version with the line referenced above removed for testing fonts at http://www.wg9s.com/acid3/test.html
Comment 8 Bill Gianopoulos [:WG9s] 2013-03-25 16:05:12 PDT
Hmm above links are incorrect.  Should be http://www.wg9s.com/mathml/acid3/ and http://www.wg9s.com/mathml/acid3/test.html

Sorry.
Comment 9 Jonathan Steele 2013-03-25 16:55:23 PDT
I uploaded one picture from http://www.wg9s.com/mathml/acid3/test.html is http://i.imgur.com/B3NWXky.png . I hope that picture can help you.
Comment 10 Bill Gianopoulos [:WG9s] 2013-03-25 17:06:38 PDT
I also have issues where this gets unexpected errors on an Android Nexus 7 tablet that it does not get on a Samsung 7 inch table that has a slightly larger screen and that both devices get a far lower score when rotated to portrait mode. I think this test is way to sensitive to the width of the screen.
Comment 11 Bill Gianopoulos [:WG9s] 2013-03-25 17:07:15 PDT
Or it has to do with the auto resizing on android to the screen width.
Comment 12 Frédéric Wang (:fredw) 2013-04-04 09:00:25 PDT
The measure can still be improved. I think using % values everywhere and measuring the default font size could help a bit. That way one could increase the font size in order to increase the precision and the test will work when the zoom is not reset or the screen is auto-resized. The "epsilon" error tolerance is currently absolute, perhaps it should be relative too (with respect to the normal or current font size). I must improve the tolerance for stretchy operators anyway (for the moment I think I use an arbitrary "10px" tolerance).

Jonathan: thanks for the picture. So it seems that the Web fonts are indeed loaded correctly and that seems a problem with the measure. Can you give the new result summary for the latest version? What about if you replace "epsilon = .0001" by "epsilon = .1"?
Comment 13 Bill Gianopoulos [:WG9s] 2013-04-04 10:31:27 PDT
(In reply to Frédéric Wang (:fredw) from comment #12)
> The measure can still be improved. I think using % values everywhere and
> measuring the default font size could help a bit. That way one could
> increase the font size in order to increase the precision and the test will
> work when the zoom is not reset or the screen is auto-resized. The "epsilon"
> error tolerance is currently absolute, perhaps it should be relative too
> (with respect to the normal or current font size). I must improve the
> tolerance for stretchy operators anyway (for the moment I think I use an
> arbitrary "10px" tolerance).

Something like that is probably the only way to get the test to pass on mobile where the behavior is to auto zoom depending on the screen width.
Comment 14 Bill Gianopoulos [:WG9s] 2013-04-07 10:04:28 PDT
(In reply to Frédéric Wang (:fredw) from comment #12)
 
> Jonathan: thanks for the picture. So it seems that the Web fonts are indeed
> loaded correctly and that seems a problem with the measure. Can you give the
> new result summary for the latest version? What about if you replace
> "epsilon = .0001" by "epsilon = .1"?

I have changed epsilon on the tests on my site form .0001 to .1

This has not helped at all with the Android issue.  Waiting for Jonathan to test on his MAC.
Comment 15 Jonathan Steele 2013-04-07 14:26:02 PDT
I changed epsilon to .1, I get 54 out of 100
Comment 16 Bill Gianopoulos [:WG9s] 2013-04-07 14:31:28 PDT
A bit better but not quite 60.
Comment 17 Frédéric Wang (:fredw) 2013-04-09 14:05:35 PDT
I've started to do the changes suggested in comment 12. I'm not done yet, but I'm curious to see if you get better results. Currently, I'm getting a score between 58 and 62 tests according to the zoom level.
Comment 18 Frédéric Wang (:fredw) 2013-04-13 03:45:37 PDT
I've continue the changes this morning (still not finished yet!). Now, I get the same score at all zoom levels. I realized that test 51 was too lax and incorrectly passed on Gecko. I fixed that and so our new expected score is 61/100.
Comment 19 Frédéric Wang (:fredw) 2013-04-13 03:47:38 PDT
Jonathan: can you please verify your score with the latest version:
http://fred-wang.github.io/AcidTestsMathML/acid3/
Comment 20 Bill Gianopoulos [:WG9s] 2013-04-13 05:23:50 PDT
(In reply to Frédéric Wang (:fredw) from comment #19)
> Jonathan: can you please verify your score with the latest version:
> http://fred-wang.github.io/AcidTestsMathML/acid3/

To help Janathan, I know have the new version at updated at http://www.wg9s.com/mathml/acid3/

This gets 62/100 on both of my tablets in either portrait or landscape.

Bad new is I lost one point under Linux (from 63/100 to 62/100)
Comment 21 Frédéric Wang (:fredw) 2013-04-13 05:35:28 PDT
(In reply to Bill Gianopoulos [:WG9s] from comment #20)
>
> This gets 62/100 on both of my tablets in either portrait or landscape.
> 
> Bad new is I lost one point under Linux (from 63/100 to 62/100)

Yes, one test was incorrect (cf comment 18). So the result should be 61/100 (62/100 with the fix for bug 827713).
Comment 22 Bill Gianopoulos [:WG9s] 2013-04-13 05:42:58 PDT
(In reply to Frédéric Wang (:fredw) from comment #21)
> (In reply to Bill Gianopoulos [:WG9s] from comment #20)
> >
> > This gets 62/100 on both of my tablets in either portrait or landscape.
> > 
> > Bad new is I lost one point under Linux (from 63/100 to 62/100)
> 
> Yes, one test was incorrect (cf comment 18). So the result should be 61/100
> (62/100 with the fix for bug 827713).

OIC that now.  I also now get 62/100 under Windows too!
Comment 23 Jonathan Steele 2013-04-13 13:08:26 PDT
I get 61/100 now.
Comment 24 Bill Gianopoulos [:WG9s] 2013-04-13 13:11:45 PDT
Great.  So no real Mozilla code issue just an issue in the test it would seem.
Comment 25 Frédéric Wang (:fredw) 2013-04-14 07:23:05 PDT
I'm done with the test rewriting, so now all the tests use only relative sizes and allow a small error. I've found yet another test that was too lax and incorrectly passed on Gecko (one of the test checking horizontal stretching in mtd cells). So the expected score should be 60/100 (or 61/100 with the fix for bug 827713). Please tell me if you get the same and then I think we can resolve this bug as FIXED.
Comment 26 Bill Gianopoulos [:WG9s] 2013-04-14 07:38:11 PDT
Matches what I get.  I can't test on Android because today's android builds are way to crashy.
Comment 27 Jonathan Steele 2013-04-14 14:32:29 PDT
(In reply to Frédéric Wang (:fredw) from comment #25)
> I'm done with the test rewriting, so now all the tests use only relative
> sizes and allow a small error. I've found yet another test that was too lax
> and incorrectly passed on Gecko (one of the test checking horizontal
> stretching in mtd cells). So the expected score should be 60/100 (or 61/100
> with the fix for bug 827713). Please tell me if you get the same and then I
> think we can resolve this bug as FIXED.

It matched with the current nightly for 60/100
Comment 28 Frédéric Wang (:fredw) 2013-04-15 01:57:41 PDT
Thanks. I close this bug.

Note You need to log in before you can comment on or make changes to this bug.