diff options
Diffstat (limited to 'testing/web-platform/tests/mathml/presentation-markup/operators/stretchy-largeop-with-default-font-3.html')
-rw-r--r-- | testing/web-platform/tests/mathml/presentation-markup/operators/stretchy-largeop-with-default-font-3.html | 145 |
1 files changed, 145 insertions, 0 deletions
diff --git a/testing/web-platform/tests/mathml/presentation-markup/operators/stretchy-largeop-with-default-font-3.html b/testing/web-platform/tests/mathml/presentation-markup/operators/stretchy-largeop-with-default-font-3.html new file mode 100644 index 0000000000..d588b9d4e0 --- /dev/null +++ b/testing/web-platform/tests/mathml/presentation-markup/operators/stretchy-largeop-with-default-font-3.html @@ -0,0 +1,145 @@ +<!DOCTYPE html> +<html> + <head> + <title>Stretchy/Largeop with default fonts</title> + <meta charset="utf-8"/> + <link rel="help" href="https://www.w3.org/TR/mathml-core/#layout-of-operators"> + <link rel="help" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1092053"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script type="text/javascript"> + function contentOf(aElement) { + return document.getElementById(aElement).textContent; + } + promise_test(() => { + return new Promise(resolve => { + window.addEventListener("load", resolve); + }).then(() => { + const numTests = 10; // zero indexed + const epsilon = 2; + for (let i = 0; i < numTests; i++) { + const operatorName = contentOf(`mo${i}`); + const box = document.getElementById(`mo${i}`).getBoundingClientRect(); + const ref = document.getElementById(`moRef${i}`).getBoundingClientRect(); + assert_approx_equals(box.width, ref.width, epsilon, `width of largeop '${operatorName}'`); + assert_approx_equals(box.height, ref.height, epsilon, `height of largeop '${operatorName}'`); + } + }); + }, "Test that non-stretchy largeops do not stretch."); + </script> + </head> + <body> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo0">⨀</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo1">⨁</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo2">⨃</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo3">⨅</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo4">⨇</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo5">⨈</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo6">⨉</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo7">⨊</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo8">⫼</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mrow> + <mspace height="3em" /> + <mo id="mo9">⫿</mo> + </mrow> + </math> + </p> + <p> + <math displaystyle="true"> + <mo id="moRef0">⨀</mo> + </math> + <math displaystyle="true"> + <mo id="moRef1">⨁</mo> + </math> + <math displaystyle="true"> + <mo id="moRef2">⨃</mo> + </math> + <math displaystyle="true"> + <mo id="moRef3">⨅</mo> + </math> + <math displaystyle="true"> + <mo id="moRef4">⨇</mo> + </math> + <math displaystyle="true"> + <mo id="moRef5">⨈</mo> + </math> + <math displaystyle="true"> + <mo id="moRef6">⨉</mo> + </math> + <math displaystyle="true"> + <mo id="moRef7">⨊</mo> + </math> + <math displaystyle="true"> + <mo id="moRef8">⫼</mo> + </math> + <math displaystyle="true"> + <mo id="moRef9">⫿</mo> + </math> + </p> + </body> +</html> |