Bug 201603 - Synchronize MathML WPT tests against upstream
[WebKit-https.git] / LayoutTests / imported / w3c / web-platform-tests / mathml / presentation-markup / mrow / inferred-mrow-stretchy.html
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <meta charset="utf-8">
5 <title>Stretchy in inferred mrows</title>
6 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#horizontally-group-sub-expressions-mrow">
7 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#radicals-msqrt-mroot">
8 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#style-change-mstyle">
9 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#error-message-merror">
10 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#making-sub-expressions-invisible-mphantom">
11 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#the-top-level-math-element">
12 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#enclose-expression-inside-notation-menclose">
13 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#adjust-space-around-content-mpadded">
14 <link rel="help" href="https://mathml-refresh.github.io/mathml-core/#operator-fence-separator-or-accent-mo">
15 <meta name="assert" content="Operators can stretch inside mrow-like elements.">
16 <script src="/mathml/support/feature-detection.js"></script>
17 <script src="/resources/testharness.js"></script>
18 <script src="/resources/testharnessreport.js"></script>
19 <style>
20   mo {
21     font-size: 10px;
22     font-family: axisheight5000-verticalarrow14000;
23   }
24   @font-face {
25     font-family: axisheight5000-verticalarrow14000;
26     src: url("/fonts/math/axisheight5000-verticalarrow14000.woff");
27   }
28 </style>
29 <script type="text/javascript">
30   setup({ explicit_done: true });
31   window.addEventListener("load", () => { document.fonts.ready.then(runTests); });
32   function runTests()
33   {
34       ["Mrow", "Sqrt", "Style", "Error", "Phantom", "Math", "Menclose", "Mpadded"].forEach((tag) => {
35           var mo = document.getElementById("mo" + tag);
36           test(function() {
37               assert_true(MathMLFeatureDetection.has_mspace());
38               assert_greater_than_equal(mo.getBoundingClientRect().height, 100);
39           }, "operator stretching inside " + tag);
40       });
41       done();
42   }
43 </script>
44 </head>
45 <body>
46   <div id="log"></div>
47   <p>
48     <math><mrow><mo id="moMrow">&#x21A8;</mo><mspace width="1px" height="100px" style="background: blue"></mspace></mrow></math>
49     <math><msqrt><mo id="moSqrt">&#x21A8;</mo><mspace width="1px" height="100px" style="background: magenta"></mspace></msqrt></math>
50     <math><mstyle><mo id="moStyle">&#x21A8;</mo><mspace width="1px" height="100px" style="background: magenta"></mspace></mstyle></math>
51     <math><merror><mo id="moError">&#x21A8;</mo><mspace width="1px" height="100px" style="background: magenta"></mspace></merror></math>
52     <math><mphantom><mo style="visibilty: visible;" id="moPhantom">&#x21A8;</mo><mspace width="1px" height="100px" style="background: magenta"></mspace></mphantom></math>
53     <math><mo id="moMath">&#x21A8;</mo><mspace width="1px" height="100px" style="background: magenta"></mspace></math>
54     <math><menclose notation="box"><mo id="moMenclose">&#x21A8;</mo><mspace width="1px" height="100px" style="background: magenta"></mspace></menclose></math>
55     <math><mpadded notation="box"><mo id="moMpadded">&#x21A8;</mo><mspace width="1px" height="100px" style="background: magenta"></mspace></mpadded></math>
56   </p>
57 </body>
58 </html>