From 8bd30833a3766189e61b357166daf3dcfc17d807 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 14 Nov 2024 14:54:30 -0500 Subject: [PATCH 01/10] Update Physics tests --- testsuite/tests/input/tex/Physics.test.ts | 3575 ++++++++++----------- 1 file changed, 1742 insertions(+), 1833 deletions(-) diff --git a/testsuite/tests/input/tex/Physics.test.ts b/testsuite/tests/input/tex/Physics.test.ts index 55cd18c5c..613dcab42 100644 --- a/testsuite/tests/input/tex/Physics.test.ts +++ b/testsuite/tests/input/tex/Physics.test.ts @@ -1334,7 +1334,7 @@ describe('Physics2_1', () => { toXmlMatch( tex2mml('\\vb{\\mbox{ab}}'), ` - + ab ` @@ -3868,26 +3868,18 @@ describe('Physics4_0', () => { toXmlMatch( tex2mml('\\qcc'), ` - - - + c.c. - - - + ` )); it('QuickQuad_0_1', () => toXmlMatch( tex2mml('\\qand'), ` - - - + and - - - + ` )); it('QuickQuad_0_2', () => @@ -3896,9 +3888,7 @@ describe('Physics4_0', () => { ` a , - - - + b ` )); @@ -3907,13 +3897,9 @@ describe('Physics4_0', () => { tex2mml('a\\qqtext{hello}b'), ` a - - - + hello - - - + b ` )); @@ -3923,9 +3909,7 @@ describe('Physics4_0', () => { ` a hello - - - + b ` )); @@ -3934,13 +3918,9 @@ describe('Physics4_0', () => { tex2mml('a\\qqtext ab'), ` a - - - + a - - - + b ` )); @@ -3950,9 +3930,7 @@ describe('Physics4_0', () => { ` a a - - - + b ` )); @@ -3965,13 +3943,9 @@ describe('Physics4_0', () => { r e e - - - + if - - - + t w o @@ -5888,9 +5862,7 @@ describe('Physics6_0', () => { - - - + @@ -6406,9 +6378,7 @@ describe('Physics6_2', () => { - - - + @@ -6434,9 +6404,7 @@ describe('Physics6_2', () => { - - - + @@ -6459,9 +6427,7 @@ describe('Physics6_2', () => { A - - - + A @@ -6481,9 +6447,7 @@ describe('Physics6_2', () => { - - - + @@ -6506,9 +6470,7 @@ describe('Physics6_2', () => { - - - + @@ -6528,9 +6490,7 @@ describe('Physics6_2', () => { a - - - + a @@ -6550,9 +6510,7 @@ describe('Physics6_2', () => { - - - + @@ -6578,9 +6536,7 @@ describe('Physics6_2', () => { - - - + @@ -6603,9 +6559,7 @@ describe('Physics6_2', () => { - - - + A @@ -6628,9 +6582,7 @@ describe('Physics6_2', () => { - - - + @@ -6657,9 +6609,7 @@ describe('Physics6_2', () => { - - - + @@ -6686,9 +6636,7 @@ describe('Physics6_2', () => { - - - + @@ -6709,9 +6657,7 @@ describe('Physics6_2', () => { - - - + | @@ -6747,9 +6693,7 @@ describe('Physics6_2', () => { - - - + @@ -6772,9 +6716,7 @@ describe('Physics6_2', () => { - - - + @@ -6797,9 +6739,7 @@ describe('Physics6_2', () => { - - - + @@ -8662,67 +8602,71 @@ describe('Physics7_11', () => { it('Matrices_Other_8', () => toXmlMatch( tex2mml('\\begin{smallmatrix} a & b \\\\ c & d \\end{smallmatrix}'), - ` - - - - a - - - b - - - - - c - - - d - - - + ` + + + + + a + + + b + + + + + c + + + d + + + + ` )); it('Matrices_Other_9', () => toXmlMatch( tex2mml('\\smqty{\\imat{3}}'), ` - - - - - 1 - - - 0 - - - 0 - - - - - 0 - - - 1 - - - 0 - - - - - 0 - - - 0 - - - 1 - - - + + + + + + 1 + + + 0 + + + 0 + + + + + 0 + + + 1 + + + 0 + + + + + 0 + + + 0 + + + 1 + + + + ` )); it('Matrices_Other_10', () => @@ -9287,66 +9231,72 @@ describe('Physics7_2', () => { toXmlMatch( tex2mml('\\smallmatrixquantity{Q}'), ` - - - - - Q - - - + + + + + + Q + + + + ` )); it('Matrices_Small_1', () => toXmlMatch( tex2mml('\\smallmatrixquantity*{a & b \\\\ c & d}'), - ` - - - - - a - - - b - - - - - c - - - d - - - -` - )); - it('Matrices_Small_2', () => - toXmlMatch( - tex2mml('\\smallmatrixquantity*(a & b \\\\ c & d)'), - ` - - - + ` + + - - a + + a - b + b - c + c - d + d + +` + )); + it('Matrices_Small_2', () => + toXmlMatch( + tex2mml('\\smallmatrixquantity*(a & b \\\\ c & d)'), + ` + + + + + + + + a + + + b + + + + + c + + + d + + + + ` @@ -9357,56 +9307,29 @@ describe('Physics7_2', () => { ` ( - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + ) -` - )); - it('Matrices_Small_4', () => - toXmlMatch( - tex2mml('\\smallmatrixquantity[a & b \\\\ c & d]'), - ` - - [ - - - - - a - - - b - - - - - c - - - d - - - - ] - ` )); it('Matrices_Small_5', () => @@ -9415,7 +9338,37 @@ describe('Physics7_2', () => { ` | - + + + + + + a + + + b + + + + + c + + + d + + + + + | + +` + )); + it('Matrices_Small_6', () => + toXmlMatch( + tex2mml('\\smqty{a & b \\\\ c & d}'), + ` + + @@ -9434,89 +9387,67 @@ describe('Physics7_2', () => { - | + +` + )); + it('Matrices_Small_7', () => + toXmlMatch( + tex2mml('\\smqty(a & b \\\\ c & d)'), + ` + + ( + + + + + + a + + + b + + + + + c + + + d + + + + + ) ` )); - it('Matrices_Small_6', () => - toXmlMatch( - tex2mml('\\smqty{a & b \\\\ c & d}'), - ` - - - - - a - - - b - - - - - c - - - d - - - -` - )); - it('Matrices_Small_7', () => - toXmlMatch( - tex2mml('\\smqty(a & b \\\\ c & d)'), - ` - - ( - - - - - a - - - b - - - - - c - - - d - - - - ) - -` - )); - it('Matrices_Small_8', () => + it('Matrices_Small_8', () => toXmlMatch( tex2mml('\\smqty*(a & b \\\\ c & d)'), ` - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + ` @@ -9527,25 +9458,27 @@ describe('Physics7_2', () => { ` [ - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + ] ` @@ -9556,25 +9489,27 @@ describe('Physics7_2', () => { ` | - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + | ` @@ -9588,26 +9523,30 @@ describe('Physics7_3', () => { ` ( - - - - - Q - - - + + + + + + Q + + + + ) ( - - - - - R - - - + + + + + + R + + + + ) ` @@ -9618,26 +9557,30 @@ describe('Physics7_3', () => { ` - - - - - Q - - - + + + + + + Q + + + + - - - - - R - - - + + + + + + R + + + + ` @@ -9648,26 +9591,30 @@ describe('Physics7_3', () => { ` [ - - - - - Q - - - + + + + + + Q + + + + ] [ - - - - - R - - - + + + + + + R + + + + ] ` @@ -9678,26 +9625,30 @@ describe('Physics7_3', () => { ` | - - - - - Q - - - + + + + + + Q + + + + | | - - - - - R - - - + + + + + + R + + + + | ` @@ -9708,25 +9659,27 @@ describe('Physics7_3', () => { ` ( - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + ) ` @@ -9737,25 +9690,27 @@ describe('Physics7_3', () => { ` - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + ` @@ -9766,25 +9721,27 @@ describe('Physics7_3', () => { ` [ - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + ] ` @@ -9795,25 +9752,27 @@ describe('Physics7_3', () => { ` | - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + | ` @@ -9883,25 +9842,27 @@ describe('Physics7_4', () => { ` | - - - - - a - - - b - - - - - c - - - d - - - + + + + + + a + + + b + + + + + c + + + d + + + + | ` @@ -9948,14 +9909,16 @@ describe('Physics7_4', () => { ` | - - - - - a - - - + + + + + + a + + + + | b @@ -10219,31 +10182,33 @@ describe('Physics7_6', () => { ` ( - - - - - 1 - - - 1 - - - 1 - - - - - 1 - - - 1 - - - 1 - - - + + + + + + 1 + + + 1 + + + 1 + + + + + 1 + + + 1 + + + 1 + + + + ) ` @@ -10254,42 +10219,44 @@ describe('Physics7_6', () => { ` ( - - - - - a - - - a - - - a - - - - - a - - - a - - - a - - - - - a - - - a - - - a - - - + + + + + + a + + + a + + + a + + + + + a + + + a + + + a + + + + + a + + + a + + + a + + + + ) ` @@ -10300,24 +10267,26 @@ describe('Physics7_6', () => { ` ( - - - - - a - - - - - a - - - - - a - - - + + + + + + a + + + + + a + + + + + a + + + + ) ` @@ -10328,20 +10297,22 @@ describe('Physics7_6', () => { ` ( - - - - - a - - - a - - - a + + + + + + a - - + + a + + + a + + + + ) ` @@ -10352,91 +10323,93 @@ describe('Physics7_6', () => { ` ( - - - - - - 1 - - - 1 - - - 1 - - - - - - - 1 - - - 1 - - - 2 - - - - - - - 1 - - - 1 - - - 3 - - - - - - - - - 1 - - - 2 + + + + + + + 1 + + + 1 + + + 1 + - - 1 + + + + + 1 + + + 1 + + + 2 + - - - - - - 1 - - - 2 + + + + + 1 + + + 1 + + + 3 + - - 2 + + + + + + + 1 + + + 2 + + + 1 + - - - - - - 1 - - - 2 + + + + + 1 + + + 2 + + + 2 + - - 3 + + + + + 1 + + + 2 + + + 3 + - - - - - + + + + + ) ` @@ -10447,175 +10420,179 @@ describe('Physics7_6', () => { ` ( - - - - - - a - - - 1 - - - 1 - - - - - - - a - - - 1 - - - 2 - - - - - - - a - - - 1 - - - 3 - - - - - - - - - a - - - 2 - - - 1 - - - - - - - a - - - 2 - - - 2 - - - - - - - a - - - 2 - - - 3 - - - - - - - - - a - - - 3 - - - 1 + + + + + + + a + + + 1 + + + 1 + - - - - - - a - - - 3 - - - 2 - - - - - - - a - - - 3 - - - 3 - - - - - - - ) - -` - )); - it('Matrices_XMatrix_6', () => - toXmlMatch( - tex2mml('\\smqty(\\xmat*{a}{3}{1})'), - ` - - ( - - - - - - a - - 1 - - - - - - - - a - - 2 - - - - - - - - a - - 3 - - - - - + + + + + a + + + 1 + + + 2 + + + + + + + a + + + 1 + + + 3 + + + + + + + + + a + + + 2 + + + 1 + + + + + + + a + + + 2 + + + 2 + + + + + + + a + + + 2 + + + 3 + + + + + + + + + a + + + 3 + + + 1 + + + + + + + a + + + 3 + + + 2 + + + + + + + a + + + 3 + + + 3 + + + + + + + + ) + +` + )); + it('Matrices_XMatrix_6', () => + toXmlMatch( + tex2mml('\\smqty(\\xmat*{a}{3}{1})'), + ` + + ( + + + + + + + a + + 1 + + + + + + + + a + + 2 + + + + + + + + a + + 3 + + + + + + ) ` @@ -10626,35 +10603,37 @@ describe('Physics7_6', () => { ` ( - - - - - - a - - 1 - - - - - - a - - 2 - - - - - - a - - 3 - - - - - + + + + + + + a + + 1 + + + + + + a + + 2 + + + + + + a + + 3 + + + + + + ) ` @@ -10665,14 +10644,16 @@ describe('Physics7_6', () => { ` ( - - - - - a - - - + + + + + + a + + + + ) ` @@ -10683,14 +10664,16 @@ describe('Physics7_6', () => { ` ( - - - - - a - - - + + + + + + a + + + + ) ` @@ -10701,20 +10684,22 @@ describe('Physics7_6', () => { ` ( - - - - - 0 - - - 0 - - - 0 - - - + + + + + + 0 + + + 0 + + + 0 + + + + ) ` @@ -10725,31 +10710,33 @@ describe('Physics7_6', () => { ` ( - - - - - 0 - - - 0 - - - 0 - - - - - 0 - - - 0 - - - 0 - - - + + + + + + 0 + + + 0 + + + 0 + + + + + 0 + + + 0 + + + 0 + + + + ) ` @@ -10760,24 +10747,26 @@ describe('Physics7_6', () => { ` ( - - - - - 0 - - - - - 0 - - - - - 0 - - - + + + + + + 0 + + + + + 0 + + + + + 0 + + + + ) ` @@ -11702,8 +11691,8 @@ describe('Physics Errors', () => { it('MissingArgFor Quantity', () => toXmlMatch( tex2mml('\\pqty'), - ` - + ` + Missing argument for \\pqty ` @@ -11711,8 +11700,8 @@ describe('Physics Errors', () => { it('MissingArgFor Eval', () => toXmlMatch( tex2mml('\\eval'), - ` - + ` + Missing argument for \\eval ` @@ -11720,8 +11709,8 @@ describe('Physics Errors', () => { it('MissingArgFor Commutator 1', () => toXmlMatch( tex2mml('\\commutator\\nix'), - ` - + ` + Missing argument for \\commutator ` @@ -11729,8 +11718,8 @@ describe('Physics Errors', () => { it('MissingArgFor Commutator 2', () => toXmlMatch( tex2mml('\\commutator'), - ` - + ` + Missing argument for \\commutator ` @@ -11738,8 +11727,8 @@ describe('Physics Errors', () => { it('InvalidNumber IdentityMatrix', () => toXmlMatch( tex2mml('\\smqty(\\identitymatrix{a})'), - ` - + ` + Invalid number ` @@ -11747,8 +11736,8 @@ describe('Physics Errors', () => { it('InvalidNumber XMatrix n', () => toXmlMatch( tex2mml('\\smqty(\\xmatrix{a}{a}{2})'), - ` - + ` + Invalid number ` @@ -11756,8 +11745,8 @@ describe('Physics Errors', () => { it('InvalidNumber XMatrix m', () => toXmlMatch( tex2mml('\\smqty(\\xmatrix{a}{2}{a})'), - ` - + ` + Invalid number ` @@ -11765,8 +11754,8 @@ describe('Physics Errors', () => { it('InvalidNumber XMatrix n+', () => toXmlMatch( tex2mml('\\smqty(\\xmatrix{a}{2.0}{2})'), - ` - + ` + Invalid number ` @@ -11774,8 +11763,8 @@ describe('Physics Errors', () => { it('InvalidNumber XMatrix m+', () => toXmlMatch( tex2mml('\\smqty(\\xmatrix{a}{2}{2.0})'), - ` - + ` + Invalid number ` @@ -11786,26 +11775,26 @@ describe('Automatic Bracing Macros Rest', () => { it('Quantities_Bracket', () => toXmlMatch( tex2mml('\\bqty\\Bigg{a}'), - ` - - [ + ` + + [ - a - - ] + a + + ] ` )); it('Quantities_Vert', () => toXmlMatch( tex2mml('\\vqty\\Bigg{a}'), - ` - - | + ` + + | - a - - | + a + + | ` )); @@ -11815,55 +11804,55 @@ describe('Vector Mo Rest', () => { it('dotproduct', () => toXmlMatch( tex2mml('A \\dotproduct B'), - ` - A - - B + ` + A + + B ` )); it('vdot', () => toXmlMatch( tex2mml('A \\vdot B'), - ` - A - - B + ` + A + + B ` )); it('cross', () => toXmlMatch( tex2mml('A \\cross B'), - ` - A - × - B + ` + A + × + B ` )); it('cp', () => toXmlMatch( tex2mml('A \\cp B'), - ` - A - × - B + ` + A + × + B ` )); it('divsymbol', () => toXmlMatch( tex2mml('A \\divsymbol B'), - ` - A - ÷ - B + ` + A + ÷ + B ` )); it('divisionsymbol', () => toXmlMatch( tex2mml('A \\divisionsymbol B'), - ` - A - ÷ - B + ` + A + ÷ + B ` )); }); @@ -11872,337 +11861,337 @@ describe('Expressions Macros Rest', () => { it('trace', () => toXmlMatch( tex2mml('\\trace(x)'), - ` + ` tr - - - ( - x - ) + + + ( + x + ) ` )); it('Tr', () => toXmlMatch( tex2mml('\\Tr(x)'), - ` + ` Tr - - - ( - x - ) + + + ( + x + ) ` )); it('Trace', () => toXmlMatch( tex2mml('\\Trace(x)'), - ` + ` Tr - - - ( - x - ) + + + ( + x + ) ` )); it('arcsine', () => toXmlMatch( tex2mml('\\arcsine(x)'), - ` - arcsin - - ( - x - ) + ` + arcsin + + ( + x + ) ` )); it('asine', () => toXmlMatch( tex2mml('\\asine(x)'), - ` - asin - - ( - x - ) + ` + asin + + ( + x + ) ` )); it('cosine', () => toXmlMatch( tex2mml('\\cosine(x)'), - ` - cos - - ( - x - ) + ` + cos + + ( + x + ) ` )); it('hypcosine', () => toXmlMatch( tex2mml('\\hypcosine(x)'), - ` - cosh - - ( - x - ) + ` + cosh + + ( + x + ) ` )); it('arccosine', () => toXmlMatch( tex2mml('\\arccosine(x)'), - ` - arccos - - ( - x - ) + ` + arccos + + ( + x + ) ` )); it('acosine', () => toXmlMatch( tex2mml('\\acosine(x)'), - ` - acos - - ( - x - ) + ` + acos + + ( + x + ) ` )); it('tangent', () => toXmlMatch( tex2mml('\\tangent(x)'), - ` - tan - - ( - x - ) + ` + tan + + ( + x + ) ` )); it('hyptangent', () => toXmlMatch( tex2mml('\\hyptangent(x)'), - ` - tanh - - ( - x - ) + ` + tanh + + ( + x + ) ` )); it('arctangent', () => toXmlMatch( tex2mml('\\arctangent(x)'), - ` - arctan - - ( - x - ) + ` + arctan + + ( + x + ) ` )); it('atangent', () => toXmlMatch( tex2mml('\\atangent(x)'), - ` - atan - - ( - x - ) + ` + atan + + ( + x + ) ` )); it('cosecant', () => toXmlMatch( tex2mml('\\cosecant(x)'), - ` - csc - - ( - x - ) + ` + csc + + ( + x + ) ` )); it('hypcosecant', () => toXmlMatch( tex2mml('\\hypcosecant(x)'), - ` - csch - - ( - x - ) + ` + csch + + ( + x + ) ` )); it('arccosecant', () => toXmlMatch( tex2mml('\\arccosecant(x)'), - ` - arccsc - - ( - x - ) + ` + arccsc + + ( + x + ) ` )); it('acosecant', () => toXmlMatch( tex2mml('\\acosecant(x)'), - ` - acsc - - ( - x - ) + ` + acsc + + ( + x + ) ` )); it('secant', () => toXmlMatch( tex2mml('\\secant(x)'), - ` - sec - - ( - x - ) + ` + sec + + ( + x + ) ` )); it('hypsecant', () => toXmlMatch( tex2mml('\\hypsecant(x)'), - ` - sech - - ( - x - ) + ` + sech + + ( + x + ) ` )); it('arcsecant', () => toXmlMatch( tex2mml('\\arcsecant(x)'), - ` - arcsec - - ( - x - ) + ` + arcsec + + ( + x + ) ` )); it('asecant', () => toXmlMatch( tex2mml('\\asecant(x)'), - ` - asec - - ( - x - ) + ` + asec + + ( + x + ) ` )); it('cotangent', () => toXmlMatch( tex2mml('\\cotangent(x)'), - ` - cot - - ( - x - ) + ` + cot + + ( + x + ) ` )); it('hypcotangent', () => toXmlMatch( tex2mml('\\hypcotangent(x)'), - ` - coth - - ( - x - ) + ` + coth + + ( + x + ) ` )); it('arccotangent', () => toXmlMatch( tex2mml('\\arccotangent(x)'), - ` - arccot - - ( - x - ) + ` + arccot + + ( + x + ) ` )); it('acotangent', () => toXmlMatch( tex2mml('\\acotangent(x)'), - ` - acot - - ( - x - ) + ` + acot + + ( + x + ) ` )); it('exponential', () => toXmlMatch( tex2mml('\\exponential(x)'), - ` - exp - - ( - x - ) + ` + exp + + ( + x + ) ` )); it('logarithm', () => toXmlMatch( tex2mml('\\logarithm(x)'), - ` - log - - ( - x - ) + ` + log + + ( + x + ) ` )); it('naturallogarithm', () => toXmlMatch( tex2mml('\\naturallogarithm(x)'), - ` - ln - - ( - x - ) + ` + ln + + ( + x + ) ` )); it('determinant', () => toXmlMatch( tex2mml('\\determinant(x)'), - ` - det - - ( - x - ) + ` + det + + ( + x + ) ` )); it('Probability', () => toXmlMatch( tex2mml('\\Probability(x)'), - ` - Pr - - ( - x - ) + ` + Pr + + ( + x + ) ` )); }); @@ -12211,32 +12200,32 @@ describe('Derivative Macros Rest', () => { it('differential', () => toXmlMatch( tex2mml('\\differential'), - ` - - d + ` + + d ` )); it('variation', () => toXmlMatch( tex2mml('\\variation'), - ` - δ + ` + δ ` )); it('derivative one arg', () => toXmlMatch( tex2mml('\\derivative{x}'), - ` - - - d + ` + + + d - - - d + + + d - x + x ` @@ -12244,19 +12233,19 @@ describe('Derivative Macros Rest', () => { it('derivative two arg', () => toXmlMatch( tex2mml('\\derivative{x}{y}'), - ` - - - - d + ` + + + + d - x + x - - - d + + + d - y + y ` @@ -12264,35 +12253,35 @@ describe('Derivative Macros Rest', () => { it('derivative three arg', () => toXmlMatch( tex2mml('\\derivative{x}{y}{z}'), - ` - - - - d + ` + + + + d - x + x - - - d + + + d - y + y - - z + + z ` )); it('partialderivative one arg', () => toXmlMatch( tex2mml('\\partialderivative{x}'), - ` - - - - - x + ` + + + + + x ` @@ -12300,15 +12289,15 @@ describe('Derivative Macros Rest', () => { it('partialderivative two arg', () => toXmlMatch( tex2mml('\\partialderivative{x}{y}'), - ` - - - - x + ` + + + + x - - - y + + + y ` @@ -12316,22 +12305,22 @@ describe('Derivative Macros Rest', () => { it('partialderivative three arg', () => toXmlMatch( tex2mml('\\partialderivative{x}{y}{z}'), - ` - - - - - - 2 + ` + + + + + + 2 - x + x - - - y - - z + + + y + + z ` @@ -12339,38 +12328,38 @@ describe('Derivative Macros Rest', () => { it('partialderivative four arg', () => toXmlMatch( tex2mml('\\partialderivative{x}{y}{z}{a}'), - ` - - - - - - 2 + ` + + + + + + 2 - x + x - - - y - - z + + + y + + z - - a + + a ` )); it('pderivative one arg', () => toXmlMatch( tex2mml('\\pderivative{x}'), - ` - - - - - x + ` + + + + + x ` @@ -12378,15 +12367,15 @@ describe('Derivative Macros Rest', () => { it('pderivative two arg', () => toXmlMatch( tex2mml('\\pderivative{x}{y}'), - ` - - - - x + ` + + + + x - - - y + + + y ` @@ -12394,22 +12383,22 @@ describe('Derivative Macros Rest', () => { it('pderivative three arg', () => toXmlMatch( tex2mml('\\pderivative{x}{y}{z}'), - ` - - - - - - 2 + ` + + + + + + 2 - x + x - - - y - - z + + + y + + z ` @@ -12417,26 +12406,26 @@ describe('Derivative Macros Rest', () => { it('pderivative four arg', () => toXmlMatch( tex2mml('\\pderivative{x}{y}{z}{a}'), - ` - - - - - - 2 + ` + + + + + + 2 - x + x - - - y - - z + + + y + + z - - a + + a ` )); @@ -12446,282 +12435,208 @@ describe('Quick Quad Macros Rest', () => { it('qq', () => toXmlMatch( tex2mml('A \\qq B'), - ` - A - - - - B - - - + ` + A + + B + ` )); it('qcomma', () => toXmlMatch( tex2mml('A \\qcomma B'), - ` - A - , - - - - B + ` + A + , + + B ` )); it('qthen', () => toXmlMatch( tex2mml('A \\qthen B'), - ` - A - - - - then - - - - B + ` + A + + then + + B ` )); it('qelse', () => toXmlMatch( tex2mml('A \\qelse B'), - ` - A - - - - else - - - - B + ` + A + + else + + B ` )); it('qotherwise', () => toXmlMatch( tex2mml('A \\qotherwise B'), - ` - A - - - - otherwise - - - - B + ` + A + + otherwise + + B ` )); it('qunless', () => toXmlMatch( tex2mml('A \\qunless B'), - ` - A - - - - unless - - - - B + ` + A + + unless + + B ` )); it('qgiven', () => toXmlMatch( tex2mml('A \\qgiven B'), - ` - A - - - - given - - - - B + ` + A + + given + + B ` )); it('qusing', () => toXmlMatch( tex2mml('A \\qusing B'), - ` - A - - - - using - - - - B + ` + A + + using + + B ` )); it('qassume', () => toXmlMatch( tex2mml('A \\qassume B'), - ` - A - - - - assume - - - - B + ` + A + + assume + + B ` )); it('qsince', () => toXmlMatch( tex2mml('A \\qsince B'), - ` - A - - - - since - - - - B + ` + A + + since + + B ` )); it('qlet', () => toXmlMatch( tex2mml('A \\qlet B'), - ` - A - - - - let - - - - B + ` + A + + let + + B ` )); it('qfor', () => toXmlMatch( tex2mml('A \\qfor B'), - ` - A - - - - for - - - - B + ` + A + + for + + B ` )); it('qall', () => toXmlMatch( tex2mml('A \\qall B'), - ` - A - - - - all - - - - B + ` + A + + all + + B ` )); it('qeven', () => toXmlMatch( tex2mml('A \\qeven B'), - ` - A - - - - even - - - - B + ` + A + + even + + B ` )); it('qodd', () => toXmlMatch( tex2mml('A \\qodd B'), - ` - A - - - - odd - - - - B + ` + A + + odd + + B ` )); it('qinteger', () => toXmlMatch( tex2mml('A \\qinteger B'), - ` - A - - - - integer - - - - B + ` + A + + integer + + B ` )); it('qor', () => toXmlMatch( tex2mml('A \\qor B'), - ` - A - - - - or - - - - B + ` + A + + or + + B ` )); it('qas', () => toXmlMatch( tex2mml('A \\qas B'), - ` - A - - - - as - - - - B + ` + A + + as + + B ` )); it('qin', () => toXmlMatch( tex2mml('A \\qin B'), - ` - A - - - - in - - - - B + ` + A + + in + + B ` )); }); @@ -12730,371 +12645,365 @@ describe('Bra-Ket Macros Rest', () => { it('innerproduct arg one', () => toXmlMatch( tex2mml('\\innerproduct{A}'), - ` - - - - A + ` + + + + A - - | - - - A + + | + + + A - + ` )); it('innerproduct arg two', () => toXmlMatch( tex2mml('\\innerproduct{A}{B}'), - ` - - - - A + ` + + + + A - - | - - - B + + | + + + B - + ` )); it('innerproduct arg three', () => toXmlMatch( tex2mml('\\innerproduct{A}{B}{C}'), - ` - - - - A + ` + + + + A - - | - - - B + + | + + + B - + - - C + + C ` )); it('ip arg one', () => toXmlMatch( tex2mml('\\ip{A}'), - ` - - - - A + ` + + + + A - - | - - - A + + | + + + A - + ` )); it('ip arg two', () => toXmlMatch( tex2mml('\\ip{A}{B}'), - ` - - - - A + ` + + + + A - - | - - - B + + | + + + B - + ` )); it('ip arg three', () => toXmlMatch( tex2mml('\\ip{A}{B}{C}'), - ` - - - - A + ` + + + + A - - | - - - B + + | + + + B - + - - C + + C ` )); it('op arg one', () => toXmlMatch( tex2mml('\\op{A}'), - ` - - | - - A + ` + + | + + A - - - - - - - - - - - A + + + + + + + + + A - | + | ` )); it('op arg two', () => toXmlMatch( tex2mml('\\op{A}{B}'), - ` - - | - - A + ` + + | + + A - - - - - - - - - - - B + + + + + + + + + B - | + | ` )); it('op arg three', () => toXmlMatch( tex2mml('\\op{A}{B}{C}'), - ` - - | - - A + ` + + | + + A - - - - - - - - - - - B + + + + + + + + + B - | + | - - C + + C ` )); it('expectationvalue arg one', () => toXmlMatch( tex2mml('\\expectationvalue{A}'), - ` - - - - A + ` + + + + A - + ` )); it('expectationvalue arg two', () => toXmlMatch( tex2mml('\\expectationvalue{A}{B}'), - ` - - - - B + ` + + + + B - | + | - - A + + A - - | - - B + + | + + B - + ` )); it('expectationvalue arg three', () => toXmlMatch( tex2mml('\\expectationvalue{A}{B}{C}'), - ` - - - - B + ` + + + + B - | + | - - A + + A - - | - - B + + | + + B - + - - C + + C ` )); it('expval arg one', () => toXmlMatch( tex2mml('\\expval{A}'), - ` - - - - A + ` + + + + A - + ` )); it('expval arg two', () => toXmlMatch( tex2mml('\\expval{A}{B}'), - ` - - - - B + ` + + + + B - | + | - - A + + A - - | - - B + + | + + B - + ` )); it('expval arg three', () => toXmlMatch( tex2mml('\\expval{A}{B}{C}'), - ` - - - - B + ` + + + + B - | + | - - A + + A - - | - - B + + | + + B - + - - C + + C ` )); it('matrixelement arg three', () => toXmlMatch( tex2mml('\\matrixelement{A}{B}{C}'), - ` - - - - A + ` + + + + A - | + | - - B + + B - - | - - C + + | + + C - + ` )); it('matrixelement arg four', () => toXmlMatch( tex2mml('\\matrixelement{A}{B}{C}{D}'), - ` - - - - A + ` + + + + A - | + | - - B + + B - - | - - C + + | + + C - + - - D + + D ` )); @@ -13104,245 +13013,245 @@ describe('Matrix Macros Rest', () => { it('zeromatrix', () => toXmlMatch( tex2mml('\\pmqty{\\zeromatrix{2}{3}}'), - ` - - ( - - + ` + + ( + + - 0 + 0 - 0 + 0 - 0 + 0 - + - 0 + 0 - 0 + 0 - 0 + 0 - ) + ) ` )); it('paulimatrix 0', () => toXmlMatch( tex2mml('\\pmqty{\\paulimatrix{0}}'), - ` - - ( - - + ` + + ( + + - 1 + 1 - 0 + 0 - + - 0 + 0 - 1 + 1 - ) + ) ` )); it('paulimatrix 1', () => toXmlMatch( tex2mml('\\pmqty{\\paulimatrix{1}}'), - ` - - ( - - + ` + + ( + + - 0 + 0 - 1 + 1 - + - 1 + 1 - 0 + 0 - ) + ) ` )); it('paulimatrix 2', () => toXmlMatch( tex2mml('\\pmqty{\\paulimatrix{2}}'), - ` - - ( - - + ` + + ( + + - 0 + 0 - - i + + i - + - i + i - 0 + 0 - ) + ) ` )); it('paulimatrix 3', () => toXmlMatch( tex2mml('\\pmqty{\\paulimatrix{3}}'), - ` - - ( - - + ` + + ( + + - 1 + 1 - 0 + 0 - + - 0 + 0 - - 1 + + 1 - ) + ) ` )); it('paulimatrix 4', () => toXmlMatch( tex2mml('\\pmqty{\\paulimatrix{4}}'), - ` - - ( - - ) + ` + + ( + + ) ` )); it('diagonalmatrix', () => toXmlMatch( tex2mml('\\pmqty{\\diagonalmatrix{0,1\\\\2&3}}'), - ` - - ( - - + ` + + ( + + - - + + - 0 + 0 - + - - + + - 1 + 1 - + - 2 + 2 - 3 + 3 - ) + ) ` )); it('antidiagonalmatrix', () => toXmlMatch( tex2mml('\\pmqty{\\antidiagonalmatrix{0,1\\\\2&3}}'), - ` - - ( - - + ` + + ( + + - - + + - 0 + 0 - + - - + + - 1 + 1 - + - 2 + 2 - 3 + 3 - ) + ) ` )); @@ -13352,38 +13261,38 @@ describe('Rest for Completion', () => { it('Issue 2831', () => toXmlMatch( tex2mml('\\exp((\\frac{a}{a}a){a})'), - ` + ` exp - - - ( - ( - - a - a + + + ( + ( + + a + a - a - ) - - a + a + ) + + a - ) + ) ` )); it('Issue 3000', () => toXmlMatch( tex2mml('\\sin(1\\over2)'), - ` + ` sin - - - ( - - 1 - 2 + + + ( + + 1 + 2 - ) + ) ` )); From 7991d6f8978f20a61f6994f6ea384384642aecde Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 14 Nov 2024 16:01:10 -0500 Subject: [PATCH 02/10] Update Ams tests --- testsuite/tests/input/tex/Ams.test.ts | 410 ++++++++++++-------------- 1 file changed, 184 insertions(+), 226 deletions(-) diff --git a/testsuite/tests/input/tex/Ams.test.ts b/testsuite/tests/input/tex/Ams.test.ts index 870d211de..c1f47fabd 100644 --- a/testsuite/tests/input/tex/Ams.test.ts +++ b/testsuite/tests/input/tex/Ams.test.ts @@ -42,13 +42,9 @@ describe('Ams', () => { tex2mml('A\\implies B'), ` A - - - + - - - + B ` )); @@ -85,7 +81,7 @@ describe('Ams', () => { toXmlMatch( tex2mml('\\tfrac{n}{k}'), ` - + n k @@ -97,12 +93,10 @@ describe('Ams', () => { toXmlMatch( tex2mml('\\dfrac{n}{k}'), ` - - - n - k - - + + n + k + ` )); it('Normal Sub Fraction', () => @@ -124,7 +118,7 @@ describe('Ams', () => { ` a - + n k @@ -170,7 +164,7 @@ describe('Ams', () => { toXmlMatch( tex2mml('\\tbinom{n}{k}'), ` - + ( @@ -190,20 +184,18 @@ describe('Ams', () => { toXmlMatch( tex2mml('\\dbinom{n}{k}'), ` - - - - ( - - - n - k - - - ) - + + + ( - + + n + k + + + ) + + ` )); it('Normal Sub Binomial', () => @@ -233,7 +225,7 @@ describe('Ams', () => { ` a - + ( @@ -282,23 +274,19 @@ describe('Ams', () => { - - - a - - + + a + - - - b - b - b - - + + b + b + b + ` @@ -312,23 +300,19 @@ describe('Ams', () => { - - - a - - + + a + - - - b - b - b - - + + b + b + b + ` @@ -342,23 +326,19 @@ describe('Ams', () => { - - - a - - + + a + - - - b - b - b - - + + b + b + b + ` @@ -368,9 +348,7 @@ describe('Ams', () => { tex2mml('\\xleftarrow{abcd}'), ` - - - + a b @@ -386,9 +364,7 @@ describe('Ams', () => { tex2mml('\\xleftarrow[xyz]{abcd}'), ` - - - + x y @@ -411,9 +387,7 @@ describe('Ams', () => { ` A - - - + a b @@ -430,9 +404,7 @@ describe('Ams', () => { tex2mml('\\xrightarrow{abcd}'), ` - - - + a b @@ -448,9 +420,7 @@ describe('Ams', () => { tex2mml('\\xrightarrow[xyz]{abcd}'), ` - - - + x y @@ -473,9 +443,7 @@ describe('Ams', () => { ` A - - - + a b @@ -543,20 +511,12 @@ describe('Ams', () => { toXmlMatch( tex2mml('\\idotsint\\limits_a^b+3'), ` - - - - - - + + - - - - - - + + @@ -581,11 +541,11 @@ describe('Ams', () => { it('Operatorname', () => toXmlMatch( tex2mml('a\\operatorname{xyz}b'), - ` - a - xyz - - b + ` + a + xyz + + b ` )); }); @@ -595,33 +555,37 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{subarray}{c}a\\end{subarray}'), ` - - - - a - - - + + + + + a + + + + ` )); it('Small Matrix', () => toXmlMatch( tex2mml('\\begin{smallmatrix}a\\end{smallmatrix}'), ` - - - - a - - - + + + + + a + + + + ` )); it('Align', () => toXmlMatch( tex2mml('\\begin{align} a&=b \\\\ c&=d \\end{align}'), ` - + a @@ -653,7 +617,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{align*} a&=b \\\\ c&=d \\end{align*}'), ` - + a @@ -685,7 +649,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{multline} a\\\\ b \\\\ c \\end{multline}'), ` - + a @@ -708,7 +672,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{multline*} a\\\\ b \\\\ c \\end{multline*}'), ` - + a @@ -733,7 +697,7 @@ describe('Ams Environments', () => { '\\begin{align*} a&=b \\begin{split} r&=s\\\\ & =t \\end{split} \\\\ c&=d \\end{align*}' ), ` - + a @@ -743,7 +707,7 @@ describe('Ams Environments', () => { = b - + r @@ -789,7 +753,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{gather} a=b \\\\ c=d \\end{gather}'), ` - + a @@ -811,7 +775,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{gather*} a=b \\\\ c=d \\end{gather*}'), ` - + a @@ -833,7 +797,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{alignat}{2} a&=b \\\\ c&=d \\end{alignat}'), ` - + a @@ -865,7 +829,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{alignat*}{2} a&=b \\\\ c&=d \\end{alignat*}'), ` - + a @@ -899,7 +863,7 @@ describe('Ams Environments', () => { '\\begin{align*} a&=b \\begin{alignedat}{2} r&=s\\\\ & =t \\end{alignedat} \\\\ c&=d \\end{align*}' ), ` - + a @@ -909,7 +873,7 @@ describe('Ams Environments', () => { = b - + r @@ -957,7 +921,7 @@ describe('Ams Environments', () => { '\\begin{align*} a&=b \\begin{aligned} r&=s\\\\ & =t \\end{aligned} \\\\ c&=d \\end{align*}' ), ` - + a @@ -967,7 +931,7 @@ describe('Ams Environments', () => { = b - + r @@ -1015,7 +979,7 @@ describe('Ams Environments', () => { '\\begin{align*} a&=b \\begin{gathered} r=s\\\\ =t \\end{gathered} \\\\ c&=d \\end{align*}' ), ` - + a @@ -1025,7 +989,7 @@ describe('Ams Environments', () => { = b - + r @@ -1076,7 +1040,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{eqnarray} a & = & b\\\\ c & = & d \\end{eqnarray}'), ` - + a @@ -1112,7 +1076,7 @@ describe('Ams Environments', () => { toXmlMatch( tex2mml('\\begin{eqnarray*} a & = & b\\\\ c & = & d \\end{eqnarray*}'), ` - + a @@ -1152,33 +1116,37 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{subarray}{c}a\\end{subarray}'), ` - - - - a - - - + + + + + a + + + + ` )); it('Small Matrix', () => toXmlMatch( tex2mml('\\begin{smallmatrix}a\\end{smallmatrix}'), ` - - - - a - - - + + + + + a + + + + ` )); it('Align', () => toXmlMatch( tex2mml('\\begin{align} a&=b \\\\ c&=d \\end{align}'), ` - + (1) @@ -1216,7 +1184,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{align*} a&=b \\\\ c&=d \\end{align*}'), ` - + a @@ -1248,7 +1216,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{multline} a\\\\ b \\\\ c \\end{multline}'), ` - + a @@ -1274,7 +1242,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{multline*} a\\\\ b \\\\ c \\end{multline*}'), ` - + a @@ -1299,7 +1267,7 @@ describe('Ams Labelled Environments', () => { '\\begin{align*} a&=b \\begin{split} r&=s\\\\ & =t \\end{split} \\\\ c&=d \\end{align*}' ), ` - + a @@ -1309,7 +1277,7 @@ describe('Ams Labelled Environments', () => { = b - + r @@ -1355,7 +1323,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{gather} a=b \\\\ c=d \\end{gather}'), ` - + (1) @@ -1383,7 +1351,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{gather*} a=b \\\\ c=d \\end{gather*}'), ` - + a @@ -1405,7 +1373,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{alignat}{2} a&=b \\\\ c&=d \\end{alignat}'), ` - + (1) @@ -1443,7 +1411,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{alignat*}{2} a&=b \\\\ c&=d \\end{alignat*}'), ` - + a @@ -1477,7 +1445,7 @@ describe('Ams Labelled Environments', () => { '\\begin{align*} a&=b \\begin{alignedat}{2} r&=s\\\\ & =t \\end{alignedat} \\\\ c&=d \\end{align*}' ), ` - + a @@ -1487,7 +1455,7 @@ describe('Ams Labelled Environments', () => { = b - + r @@ -1535,7 +1503,7 @@ describe('Ams Labelled Environments', () => { '\\begin{align*} a&=b \\begin{aligned} r&=s\\\\ & =t \\end{aligned} \\\\ c&=d \\end{align*}' ), ` - + a @@ -1545,7 +1513,7 @@ describe('Ams Labelled Environments', () => { = b - + r @@ -1593,7 +1561,7 @@ describe('Ams Labelled Environments', () => { '\\begin{align*} a&=b \\begin{gathered} r=s\\\\ =t \\end{gathered} \\\\ c&=d \\end{align*}' ), ` - + a @@ -1603,7 +1571,7 @@ describe('Ams Labelled Environments', () => { = b - + r @@ -1640,7 +1608,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{equation} a \\end{equation}'), ` - + (1) @@ -1663,7 +1631,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{eqnarray} a & = & b\\\\ c & = & d \\end{eqnarray}'), ` - + (1) @@ -1705,7 +1673,7 @@ describe('Ams Labelled Environments', () => { toXmlMatch( tex2mml('\\begin{eqnarray*} a & = & b\\\\ c & = & d \\end{eqnarray*}'), ` - + a @@ -1795,7 +1763,7 @@ describe('InternalMath', () => { tex2mml('a\\mbox{ \\eqref{1} } c'), ` a - +   @@ -1906,7 +1874,7 @@ describe('MultlineShove', () => { toXmlMatch( tex2mml('\\begin{multline} a\\\\ b\\\\ c\\end{multline}'), ` - + a @@ -1929,7 +1897,7 @@ describe('MultlineShove', () => { toXmlMatch( tex2mml('\\begin{multline}\\shoveleft a\\\\ b\\\\ c\\end{multline}'), ` - + a @@ -1952,7 +1920,7 @@ describe('MultlineShove', () => { toXmlMatch( tex2mml('\\begin{multline} a\\\\\\shoveleft b\\\\ c\\end{multline}'), ` - + a @@ -1975,7 +1943,7 @@ describe('MultlineShove', () => { toXmlMatch( tex2mml('\\begin{multline} a\\\\ b\\\\\\shoveleft c\\end{multline}'), ` - + a @@ -1998,7 +1966,7 @@ describe('MultlineShove', () => { toXmlMatch( tex2mml('\\begin{multline}\\shoveright a\\\\ b\\\\ c\\end{multline}'), ` - + a @@ -2021,7 +1989,7 @@ describe('MultlineShove', () => { toXmlMatch( tex2mml('\\begin{multline} a\\\\\\shoveright b\\\\ c\\end{multline}'), ` - + a @@ -2044,7 +2012,7 @@ describe('MultlineShove', () => { toXmlMatch( tex2mml('\\begin{multline} a\\\\ b\\\\\\shoveright c\\end{multline}'), ` - + a @@ -2069,7 +2037,7 @@ describe('MultlineShove', () => { '\\begin{multline} a\\\\\\shoveright\\shoveleft b\\\\ c\\end{multline}' ), ` - + a @@ -2094,7 +2062,7 @@ describe('MultlineShove', () => { '\\begin{multline} a\\\\\\shoveleft\\shoveright b\\\\ c\\end{multline}' ), ` - + a @@ -2158,7 +2126,7 @@ describe('Ams Complex', () => { '\\begin{align}\\dot{x} & = \\sigma(y-x) \\\\\\dot{y} & = \\rho x - y - xz \\\\\\dot{z} & = -\\beta z + xy\\end{align}' ), ` - + @@ -2235,7 +2203,7 @@ describe('Ams Complex', () => { '\\begin{align} \\nabla \\times \\vec{\\mathbf{B}} -\\, \\frac1c\\, \\frac{\\partial\\vec{\\mathbf{E}}}{\\partial t} & = \\frac{4\\pi}{c}\\vec{\\mathbf{j}} \\\\ \\nabla \\cdot \\vec{\\mathbf{E}} & = 4 \\pi \\rho \\\\ \\nabla \\times \\vec{\\mathbf{E}}\\, +\\, \\frac1c\\, \\frac{\\partial\\vec{\\mathbf{B}}}{\\partial t} & = \\vec{\\mathbf{0}} \\\\ \\nabla \\cdot \\vec{\\mathbf{B}} & = 0 \\end{align}' ), ` - + @@ -2249,16 +2217,12 @@ describe('Ams Complex', () => { - - - + 1 c - - - + @@ -2334,20 +2298,14 @@ describe('Ams Complex', () => { - - - + + - - - + 1 c - - - + @@ -2525,27 +2483,27 @@ describe('Ams SideSet', () => { it('Sideset Empty', () => toXmlMatch( tex2mml('\\sideset{}{}{}'), - ` - + ` + ` )); it('Sideset Simple', () => toXmlMatch( tex2mml('\\sideset{}{}{a}'), - ` - - a + ` + + a ` )); it('Sideset Simple Right', () => toXmlMatch( tex2mml('\\sideset{}{\'}{a}'), - ` - - - a - + ` + + + a + ` @@ -2553,12 +2511,12 @@ describe('Ams SideSet', () => { it('Sideset Simple Left', () => toXmlMatch( tex2mml('\\sideset{\'}{}{a}'), - ` - - - a + ` + + + a - + @@ -2567,14 +2525,14 @@ describe('Ams SideSet', () => { it('Sideset Simple Left Right', () => toXmlMatch( tex2mml('\\sideset{\'}{\'}{a}'), - ` - - - a - + ` + + + a + - + @@ -2583,24 +2541,24 @@ describe('Ams SideSet', () => { it('Sideset Simple Sum', () => toXmlMatch( tex2mml('\\sideset{}{\'}\\sum_{n=0}^{k}n'), - ` - - - - - + ` + + + + + - - n - = - 0 + + n + = + 0 - - k + + k - n + n ` )); }); From 37db25999a8dd20d489a005d1045a05578240034 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 14 Nov 2024 16:07:57 -0500 Subject: [PATCH 03/10] Update Amscd tests --- testsuite/tests/input/tex/Amscd.test.ts | 54 ++++++++++++------------- 1 file changed, 26 insertions(+), 28 deletions(-) diff --git a/testsuite/tests/input/tex/Amscd.test.ts b/testsuite/tests/input/tex/Amscd.test.ts index f178fd991..1c9bfc59d 100644 --- a/testsuite/tests/input/tex/Amscd.test.ts +++ b/testsuite/tests/input/tex/Amscd.test.ts @@ -9,7 +9,7 @@ describe('AmsCD', () => { toXmlMatch( tex2mml('\\begin{CD}A @>a>> B\\\\@VVbV @VVcV\\\\C @>d>> D\\end{CD}'), ` - + A @@ -79,7 +79,7 @@ describe('AmsCD', () => { toXmlMatch( tex2mml('\\begin{CD}A @<<< B @>>> C\\\\@. @| @AAA\\\\@. D @= E\\end{CD}'), ` - + A @@ -142,7 +142,7 @@ describe('AmsCD', () => { toXmlMatch( tex2mml('\\begin{CD}A @>a>b> B\\\\@VlVrV @AlArA\\\\C @ - + A @@ -234,7 +234,7 @@ describe('AmsCD', () => { '\\begin{CD}A @>>> B@>\\text{very long label}>>C\\\\@VVV @VVV @VVV\\\\D @>>> E@>>> F\\end{CD}' ), ` - + A @@ -314,7 +314,7 @@ describe('AmsCD', () => { '\\begin{CD}A @>>> B @>{\\text{very long label}}>> C \\\\@VVV @VVV @VVV \\\\D @>>> E @>{\\phantom{\\text{very long label}}}>> F\\end{CD}' ), ` - + A @@ -402,7 +402,7 @@ describe('AmsCD', () => { '\\begin{CD}A @>>> B @>{\\text{very long label}}>> C \\\\@VVV @VVV @VVV \\\\D @>>> E @>{\\rlap{\\scriptstyle{\\ \\ \\ \\text{shorter}}}\\phantom{\\text{very long label}}}>> F\\end{CD}' ), ` - + A @@ -470,14 +470,12 @@ describe('AmsCD', () => { - - -   -   -   - shorter - - + +   +   +   + shorter + @@ -502,7 +500,7 @@ describe('AmsCD', () => { '\\minCDarrowwidth{5cm}\\begin{CD}A @>a>> B\\\\@VVbV @VVcV\\\\C @>d>> D\\end{CD}' ), ` - + A @@ -574,7 +572,7 @@ describe('AmsCD', () => { '\\minCDarrowheight{4cm}\\begin{CD}A @>a>> B\\\\@VVbV @VVcV\\\\C @>d>> D\\end{CD}' ), ` - + A @@ -646,7 +644,7 @@ describe('AmsCD', () => { '\\minCDarrowheight{4cm}\\minCDarrowwidth{5cm}\\begin{CD}A @>a>> B\\\\@VVbV @VVcV\\\\C @>d>> D\\end{CD}' ), ` - + A @@ -715,20 +713,20 @@ describe('AmsCD', () => { it('Suspicious Return', () => toXmlMatch( tex2mml('\\begin{CD}A @Ra>> BaD\\end{CD}'), - ` - + ` + - A - - @ + A + + @ - R - a - >> - B - a - D + R + a + >> + B + a + D From 1bbd614aa1324460331ed3066cda37fd2afcece8 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 14 Nov 2024 17:07:25 -0500 Subject: [PATCH 04/10] Update Base tests --- testsuite/tests/input/tex/Base.test.ts | 4258 ++++++++++++------------ 1 file changed, 2089 insertions(+), 2169 deletions(-) diff --git a/testsuite/tests/input/tex/Base.test.ts b/testsuite/tests/input/tex/Base.test.ts index 66f8d8901..8744eb0dd 100644 --- a/testsuite/tests/input/tex/Base.test.ts +++ b/testsuite/tests/input/tex/Base.test.ts @@ -460,11 +460,11 @@ describe('Roots', () => { it('Square Root Fraction', () => toXmlMatch( tex2mml('\\sqrt\\frac{a}{b}'), - ` - - - a - b + ` + + + a + b ` @@ -1153,12 +1153,8 @@ describe('Mathchoice', () => { a mod - - - - - - + + b ` )); @@ -1279,23 +1275,23 @@ describe('Mathchoice', () => { it(`Pmod`, () => toXmlMatch( tex2mml('a \\pmod b'), - ` - a - - ( - mod - - b - ) + ` + a + + ( + mod + + b + ) ` )); it(`Bmod`, () => toXmlMatch( tex2mml('a \\bmod b'), - ` - a - mod - b + ` + a + mod + b ` )); }); @@ -1334,11 +1330,11 @@ describe('Stacking expressions', () => { it('Overunderset', () => toXmlMatch( tex2mml('\\overunderset{a}{b}{c}'), - ` - - c - b - a + ` + + c + b + a ` )); @@ -1826,63 +1822,63 @@ describe('Stacking expressions', () => { it('stackrel', () => toXmlMatch( tex2mml('x\\stackrel{a}{b}y'), - ` - x - - - - b + ` + x + + + + b - - a + + a - y + y ` )); it('stackbin', () => toXmlMatch( tex2mml('x\\stackbin{a}{b}y'), - ` - x - - - - b + ` + x + + + + b - - a + + a - y + y ` )); it('atop', () => toXmlMatch( tex2mml('a \\atop b'), - ` - - a - b + ` + + a + b ` )); it('atopwithdelims', () => toXmlMatch( tex2mml('a \\atopwithdelims [ ] b'), - ` - - - [ + ` + + + [ - - a - b + + a + b - - ] + + ] ` @@ -1890,17 +1886,17 @@ describe('Stacking expressions', () => { it('brack', () => toXmlMatch( tex2mml('n \\brack k'), - ` - - - [ + ` + + + [ - - n - k + + n + k - - ] + + ] ` @@ -1908,17 +1904,17 @@ describe('Stacking expressions', () => { it('brace', () => toXmlMatch( tex2mml('n \\brace k'), - ` - - - { + ` + + + { - - n - k + + n + k - - } + + } ` @@ -1959,36 +1955,36 @@ describe('MmlToken', () => { it('MmlToken mo', () => toXmlMatch( tex2mml('\\mmlToken{mo}{rem}'), - ` - rem + ` + rem ` )); it('MmlToken mi', () => toXmlMatch( tex2mml('\\mmlToken{mi}{=}'), - ` - = + ` + = ` )); it('MmlToken attribute', () => toXmlMatch( tex2mml('\\mmlToken{mo}[mathvariant=normal]{=}'), - ` - = + ` + = ` )); it('MmlToken attribute boolean', () => toXmlMatch( tex2mml('\\mmlToken{mo}[mathvariant=normal,largeop=true]{=}'), - ` - = + ` + = ` )); it('MmlToken attribute boolean false', () => toXmlMatch( tex2mml('\\mmlToken{mo}[mathvariant=normal,largeop=false]{=}'), - ` - = + ` + = ` )); it('Token Illegal Type', () => @@ -2217,96 +2213,88 @@ describe('Matrix', () => { it('Matrix Cases two columns', () => toXmlMatch( tex2mml('\\cases{a & b}'), - ` - - { - - + ` + + { + + - a + a - - b - + b - + ` )); it('Matrix Cases two columns braces', () => toXmlMatch( tex2mml('\\cases{a & {b}}'), - ` - - { - - + ` + + { + + - a + a - - {b} - + {b} - + ` )); it('Matrix Cases two rows', () => toXmlMatch( tex2mml('\\cases{a & b\\\\ c & d}'), - ` - - { - - + ` + + { + + - a + a - - b - + b - + - c + c - - d - + d - + ` )); it('Matrix Cases text', () => toXmlMatch( tex2mml('\\cases{a & \\text{b}}'), - ` - - { - - + ` + + { + + - a + a - b + b - + ` )); @@ -2314,7 +2302,7 @@ describe('Matrix', () => { toXmlMatch( tex2mml('\\eqalignno{a&b&c}'), ` - + c @@ -2332,17 +2320,17 @@ describe('Matrix', () => { it('Matrix Numbered Left', () => toXmlMatch( tex2mml('\\leqalignno{a&b&c}'), - ` - - + ` + + - c + c - a + a - b + b @@ -2351,17 +2339,17 @@ describe('Matrix', () => { it('Matrix Not Numbered', () => toXmlMatch( tex2mml('\\eqalign{a&b&c}'), - ` - - + ` + + - a + a - b + b - c + c @@ -2370,16 +2358,16 @@ describe('Matrix', () => { it('Displaylines', () => toXmlMatch( tex2mml('\\displaylines{a\\\\ b}'), - ` - - + ` + + - a + a - + - b + b @@ -2408,13 +2396,11 @@ describe('InternalMath', () => { tex2mml('a\\mbox{ b $a\\mbox{ b c } c$ c } c'), ` a - +  b  a - -  b c  - +  b c  c  c  @@ -2427,7 +2413,7 @@ describe('InternalMath', () => { tex2mml('a\\mbox{ ${ab}$ } c'), ` a - +   @@ -2445,7 +2431,7 @@ describe('InternalMath', () => { tex2mml('a\\mbox{aa \\\\ bb} c'), ` a - + aa \\ bb c @@ -2465,7 +2451,7 @@ describe('InternalMath', () => { tex2mml('a\\mbox{aa \\(\\frac{a}{b}\\) bb} c'), ` a - + aa  @@ -2790,11 +2776,11 @@ describe('Array', () => { toXmlMatch( tex2mml('\\eqalignno{a & & {\\hbox{(3)}}}'), ` - + - + (3) @@ -3039,22 +3025,22 @@ describe('Array', () => { it('Newcolumntype', () => toXmlMatch( tex2mml('\\newcolumntype{a}{c}\\begin{array}{a|a}a&b\\\\c&d\\end{array}'), - ` - - + ` + + - a + a - b + b - + - c + c - d + d @@ -3063,22 +3049,22 @@ describe('Array', () => { it('Newcolumntype Option', () => toXmlMatch( tex2mml('\\newcolumntype{a}[1]{c}\\begin{array}{a|a}a&b\\\\c&d\\end{array}'), - ` - - + ` + + - a + a - b + b - + - c + c - d + d @@ -3087,8 +3073,8 @@ describe('Array', () => { it('Newcolumntype Error Argument', () => toXmlMatch( tex2mml('\\newcolumntype{ab}{c}\\begin{array}{a|a}a&b\\\\c&d\\end{array}'), - ` - + ` + Column specifier must be exactly one character: ab ` @@ -3096,8 +3082,8 @@ describe('Array', () => { it('Newcolumntype Error Option', () => toXmlMatch( tex2mml('\\newcolumntype{a}[-1]{c}\\begin{array}{a|a}a&b\\\\c&d\\end{array}'), - ` - + ` + Argument to -1 must be a positive integer ` @@ -3363,12 +3349,12 @@ describe('Moving limits', () => { it('Underleftrightarrow', () => toXmlMatch( tex2mml('\\underleftrightarrow{abc}'), - ` - - - a - b - c + ` + + + a + b + c @@ -3741,10 +3727,10 @@ describe('Other', () => { it('CKJ', () => toXmlMatch( tex2mml('褯¥'), - ` - - - ¥ + ` + + + ¥ ` )); @@ -4005,107 +3991,103 @@ describe('Base Complex', () => { '1 + \\frac{q^2}{(1-q)} + \\frac{q^6}{(1-q)(1-q^2)} + \\cdots =\\prod_{j=0}^{\\infty} \\frac{1}{(1-q^{5j+2})(1-q^{5j+3})}, \\quad\\quad \\text{for $|q|<1$}.' ), ` - 1 - + - - - q - 2 - - - ( - 1 - - q - ) - - - + - - - q - 6 - - - ( 1 - - q - ) - ( - 1 - - - q - 2 - - ) - - - + - - = - - - - j - = - 0 - - - - - - - 1 - - ( - 1 - - - q - - 5 - j - + + + + + + q 2 + + + ( + 1 + + q + ) - - ) - ( - 1 - - - q - - 5 + + + + + + q + 6 + + + ( + 1 + + q + ) + ( + 1 + + + q + 2 + + ) + + + + + + = + + + j - + - 3 + = + 0 - - ) - - - , - - - - - - - - for  - - | - q - | - < - 1 - - - . -` + + + + + + 1 + + ( + 1 + + + q + + 5 + j + + + 2 + + + ) + ( + 1 + + + q + + 5 + j + + + 3 + + + ) + + + , + + + + for  + + | + q + | + < + 1 + + + . + ` )); it('A Summation Formula', () => toXmlMatch( @@ -4225,19 +4207,19 @@ describe('Environments', () => { it('Eqnarray', () => toXmlMatch( tex2mml('\\begin{eqnarray}a&=&b\\end{eqnarray}'), - ` - + ` + - a + a - = + = - - b + + b @@ -4247,34 +4229,34 @@ describe('Environments', () => { it('Equation', () => toXmlMatch( tex2mml('\\begin{equation}a=b\\end{equation}'), - ` - a - = - b + ` + a + = + b ` )); it('Displaymath', () => toXmlMatch( tex2mml('\\begin{displaymath}a\\end{displaymath}'), - ` - a + ` + a ` )); it('math', () => toXmlMatch( tex2mml('\\begin{math}a\\end{math}'), - ` - a + ` + a ` )); it('Array Center', () => toXmlMatch( tex2mml('\\begin{array}{c}a\\end{array}'), - ` - - + ` + + - a + a @@ -4283,16 +4265,16 @@ describe('Environments', () => { it('Array Center Lines', () => toXmlMatch( tex2mml('\\begin{array}{c}a\\\\b\\end{array}'), - ` - - + ` + + - a + a - + - b + b @@ -4301,17 +4283,17 @@ describe('Environments', () => { it('Array RCL', () => toXmlMatch( tex2mml('\\begin{array}{rcl}a&=&b\\end{array}'), - ` - - + ` + + - a + a - = + = - b + b @@ -4320,28 +4302,28 @@ describe('Environments', () => { it('Array RCL Lines', () => toXmlMatch( tex2mml('\\begin{array}{rcl}a&=&b\\\\c&=&d\\end{array}'), - ` - - + ` + + - a + a - = + = - b + b - + - c + c - = + = - d + d @@ -4350,11 +4332,11 @@ describe('Environments', () => { it('Display Array Center', () => toXmlMatch( tex2mml('\\begin{darray}{c}a\\end{darray}'), - ` - - + ` + + - a + a @@ -4363,16 +4345,16 @@ describe('Environments', () => { it('Display Array Center Lines', () => toXmlMatch( tex2mml('\\begin{darray}{c}a\\\\b\\end{darray}'), - ` - - + ` + + - a + a - + - b + b @@ -4381,17 +4363,17 @@ describe('Environments', () => { it('Display Array RCL', () => toXmlMatch( tex2mml('\\begin{darray}{rcl}a&=&b\\end{darray}'), - ` - - + ` + + - a + a - = + = - b + b @@ -4400,28 +4382,28 @@ describe('Environments', () => { it('Display Array RCL Lines', () => toXmlMatch( tex2mml('\\begin{darray}{rcl}a&=&b\\\\c&=&d\\end{darray}'), - ` - - + ` + + - a + a - = + = - b + b - + - c + c - = + = - d + d @@ -4430,18 +4412,18 @@ describe('Environments', () => { it('IndentAlign', () => toXmlMatch( tex2mml('\\begin{indentalign}[10cm][20cm][30cm]{lcr}a\\end{indentalign}'), - ` - - a + ` + + a ` )); it('IndentAlign Single', () => toXmlMatch( tex2mml('\\begin{indentalign}[10cm][20cm][30cm]{c}a\\end{indentalign}'), - ` - - a + ` + + a ` )); @@ -4451,8 +4433,8 @@ describe('Environment Errors', () => { it('IndentAlign BadAlignment', () => toXmlMatch( tex2mml('\\begin{indentalign}[10cm][20cm][30cm]{lkr}a\\end{indentalign}'), - ` - + ` + Alignment must be one to three copies of l, c, or r ` @@ -4460,8 +4442,8 @@ describe('Environment Errors', () => { it('IndentAlign BadDimension', () => toXmlMatch( tex2mml('\\begin{indentalign}[10cm][20cm][30]{lcr}a\\end{indentalign}'), - ` - + ` + Bracket argument to \\begin{indentalign} must be a dimension ` @@ -4469,8 +4451,8 @@ describe('Environment Errors', () => { it('BreakAlign BadBreakAlign', () => toXmlMatch( tex2mml('\\begin{indentalign}[10cm][20cm][30]{lcr}a\\end{indentalign}'), - ` - + ` + Bracket argument to \\begin{indentalign} must be a dimension ` @@ -4481,19 +4463,19 @@ describe('BreakAlign', () => { it('BreakAlign Case c', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{c}{t}a&=&b\\end{eqnarray}'), - ` - + ` + - - a + + a - = + = - - b + + b @@ -4503,19 +4485,19 @@ describe('BreakAlign', () => { it('BreakAlign Case c second cell', () => toXmlMatch( tex2mml('\\begin{eqnarray}a&\\breakAlign{c}{t}=&b\\end{eqnarray}'), - ` - + ` + - a + a - + - = + = - - b + + b @@ -4525,19 +4507,19 @@ describe('BreakAlign', () => { it('BreakAlign Case r', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{r}{t}a&=&b\\end{eqnarray}'), - ` - - + ` + + - a + a - = + = - - b + + b @@ -4547,33 +4529,33 @@ describe('BreakAlign', () => { it('BreakAlign Case r second row', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{r}{t}a&=&b\\\\\\breakAlign{r}{t}c&=&d\\end{eqnarray}'), - ` - - + ` + + - a + a - = + = - - b + + b - + - c + c - = + = - - d + + d @@ -4583,19 +4565,19 @@ describe('BreakAlign', () => { it('BreakAlign Case r multi split', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{r}{tbmc}a&=&b\\end{eqnarray}'), - ` - - + ` + + - a + a - = + = - - b + + b @@ -4605,19 +4587,19 @@ describe('BreakAlign', () => { it('BreakAlign Case t', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{t}{t}a&=&b\\end{eqnarray}'), - ` - + ` + - a + a - = + = - - b + + b @@ -4630,8 +4612,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign not in environment', () => toXmlMatch( tex2mml('\\breakAlign{c}{t}'), - ` - + ` + \\breakAlign must be used in an alignment environment ` @@ -4639,8 +4621,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case c', () => toXmlMatch( tex2mml('\\begin{eqnarray}a\\breakAlign{c}{t}&=&b\\end{eqnarray}'), - ` - + ` + \\breakAlign{c} must be at the beginning of an alignment entry ` @@ -4648,8 +4630,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case c split', () => toXmlMatch( tex2mml('\\begin{eqnarray}a\\breakAlign{c}{tb}&=&b\\end{eqnarray}'), - ` - + ` + \\breakAlign{c} must be at the beginning of an alignment entry ` @@ -4657,8 +4639,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case r', () => toXmlMatch( tex2mml('\\begin{eqnarray}a&=&\\breakAlign{r}{t}b\\end{eqnarray}'), - ` - + ` + \\breakAlign{r} must be at the beginning of an alignment row ` @@ -4666,8 +4648,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case t', () => toXmlMatch( tex2mml('\\begin{eqnarray}a&=&\\breakAlign{t}{t}b\\end{eqnarray}'), - ` - + ` + \\breakAlign{t} must be at the beginning of an alignment ` @@ -4675,8 +4657,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case t second row', () => toXmlMatch( tex2mml('\\begin{eqnarray}a&=&b\\\\\\breakAlign{t}{t}c&=&d\\end{eqnarray}'), - ` - + ` + \\breakAlign{t} must be at the beginning of an alignment ` @@ -4684,8 +4666,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case t split', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{c}{tb}a&=&b\\end{eqnarray}'), - ` - + ` + Too many alignment characters: tb ` @@ -4693,8 +4675,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case unknown', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{a}{t}a&=&b\\end{eqnarray}'), - ` - + ` + First argument to \\breakAlign must be one of c, r, or t ` @@ -4702,8 +4684,8 @@ describe('BreakAlign Errors', () => { it('BreakAlign Case unknown split', () => toXmlMatch( tex2mml('\\begin{eqnarray}\\breakAlign{t}{a}a&=&b\\end{eqnarray}'), - ` - + ` + Invalid alignment character: a ` @@ -4715,90 +4697,90 @@ describe('Setting sizes', () => { it('tiny', () => toXmlMatch( tex2mml('\\tiny a'), - ` - - a + ` + + a ` )); it('Tiny', () => toXmlMatch( tex2mml('\\Tiny a'), - ` - - a + ` + + a ` )); it('scriptsize', () => toXmlMatch( tex2mml('\\scriptsize a'), - ` - - a + ` + + a ` )); it('small', () => toXmlMatch( tex2mml('\\small a'), - ` - - a + ` + + a ` )); it('normalsize', () => toXmlMatch( tex2mml('\\normalsize a'), - ` - - a + ` + + a ` )); it('large', () => toXmlMatch( tex2mml('\\large a'), - ` - - a + ` + + a ` )); it('Large', () => toXmlMatch( tex2mml('\\Large a'), - ` - - a + ` + + a ` )); it('LARGE', () => toXmlMatch( tex2mml('\\LARGE a'), - ` - - a + ` + + a ` )); it('huge', () => toXmlMatch( tex2mml('\\huge a'), - ` - - a + ` + + a ` )); it('Huge', () => toXmlMatch( tex2mml('\\Huge a'), - ` - - a + ` + + a ` )); @@ -4810,9 +4792,7 @@ describe('Spaces', () => { tex2mml('a\\quad b'), ` a - - - + b ` )); @@ -4821,12 +4801,8 @@ describe('Spaces', () => { tex2mml('a\\!\\!b'), ` a - - - - - - + + b ` )); @@ -4835,132 +4811,112 @@ describe('Spaces', () => { tex2mml('A\\,B'), ` A - - - + B ` )); it('spaces :', () => toXmlMatch( tex2mml('A\\:B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces >', () => toXmlMatch( tex2mml('A\\>B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces ;', () => toXmlMatch( tex2mml('A\\;B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces !', () => toXmlMatch( tex2mml('A\\!B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces quad', () => toXmlMatch( tex2mml('A\\quad B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces qquad', () => toXmlMatch( tex2mml('A\\qquad B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces enspace', () => toXmlMatch( tex2mml('A\\enspace B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces thinspace', () => toXmlMatch( tex2mml('A\\thinspace B'), - ` - A - - - - B + ` + A + + B ` )); it('spaces negthinspace', () => toXmlMatch( tex2mml('A\\negthinspace B'), - ` - A - - - - B + ` + A + + B ` )); it('Hfil', () => toXmlMatch( tex2mml('\\begin{array}{cc}a&\\hfil b\\\\d&ccc\\end{array}'), - ` - - + ` + + - a + a - - b + + b - + - d + d - c - c - c + c + c + c @@ -4969,24 +4925,24 @@ describe('Spaces', () => { it('Hfill', () => toXmlMatch( tex2mml('\\begin{array}{cc}a&\\hfill b\\\\d&ccc\\end{array}'), - ` - - + ` + + - a + a - - b + + b - + - d + d - c - c - c + c + c + c @@ -4995,24 +4951,24 @@ describe('Spaces', () => { it('Hfilll', () => toXmlMatch( tex2mml('\\begin{array}{cc}a&\\hfilll b\\\\d&ccc\\end{array}'), - ` - - + ` + + - a + a - - b + + b - + - d + d - c - c - c + c + c + c @@ -5025,304 +4981,302 @@ describe('Delimiters', () => { it('<', () => toXmlMatch( tex2mml('< a >'), - ` - < - a - > + ` + < + a + > ` )); it('left right <', () => toXmlMatch( tex2mml('\\left< a \\right>'), - ` - - - a - + ` + + + a + ` )); it('lt', () => toXmlMatch( tex2mml('\\lt a \\gt'), - ` - < - a - > + ` + < + a + > ` )); it('left right lt', () => toXmlMatch( tex2mml('\\left\\lt a \\right\\gt'), - ` - - - a - + ` + + + a + ` )); it('/', () => toXmlMatch( tex2mml('/ a \\\\'), - ` - - / + ` + + / - a - + a + ` )); it('left right /', () => toXmlMatch( tex2mml('\\left/ a \\right\\\\'), - ` - - / - a - \\ - - ` + ` + + Missing or unrecognized delimiter for \\right + +` )); it('lmoustache', () => toXmlMatch( tex2mml('\\lmoustache a \\rmoustache'), - ` - - a - + ` + + a + ` )); it('left right lmoustache', () => toXmlMatch( tex2mml('\\left\\lmoustache a \\right\\rmoustache'), - ` - - - a - + ` + + + a + ` )); it('lgroup', () => toXmlMatch( tex2mml('\\lgroup a \\rgroup'), - ` - - a - + ` + + a + ` )); it('left right lgroup', () => toXmlMatch( tex2mml('\\left\\lgroup a \\right\\rgroup'), - ` - - - a - + ` + + + a + ` )); it('arrowvert', () => toXmlMatch( tex2mml('\\arrowvert a \\Arrowvert'), - ` - - a - + ` + + a + ` )); it('left right arrowvert', () => toXmlMatch( tex2mml('\\left\\arrowvert a \\right\\Arrowvert'), - ` - - - a - + ` + + + a + ` )); it('bracevert', () => toXmlMatch( tex2mml('\\bracevert a \\Vert'), - ` - - a - + ` + + a + ` )); it('left right bracevert', () => toXmlMatch( tex2mml('\\left\\bracevert a \\right\\Vert'), - ` - - - a - + ` + + + a + ` )); it('updownarrow', () => toXmlMatch( tex2mml('\\updownarrow a \\Updownarrow'), - ` - - a - + ` + + a + ` )); it('left right updownarrow', () => toXmlMatch( tex2mml('\\left\\updownarrow a \\right\\Updownarrow'), - ` - - - a - + ` + + + a + ` )); it('backslash', () => toXmlMatch( tex2mml('/ a \\backslash'), - ` - - / + ` + + / - a - \\ + a + \\ ` )); it('left right left/', () => toXmlMatch( tex2mml('\\left/ a \\right\\backslash'), - ` - - / - a - \\ + ` + + / + a + \\ ` )); it('Uparrow', () => toXmlMatch( tex2mml('\\Uparrow a \\Downarrow'), - ` - - a - + ` + + a + ` )); it('left right Uparrow', () => toXmlMatch( tex2mml('\\left\\Uparrow a \\right\\Downarrow'), - ` - - - a - + ` + + + a + ` )); it('rangle', () => toXmlMatch( tex2mml('\\rangle a \\langle'), - ` - - a - + ` + + a + ` )); it('left right rangle', () => toXmlMatch( tex2mml('\\left\\rangle a \\right\\langle'), - ` - - - a - + ` + + + a + ` )); it('rbrace', () => toXmlMatch( tex2mml('\\rbrace a \\lbrace'), - ` - } - a - { + ` + } + a + { ` )); it('left right rbrace', () => toXmlMatch( tex2mml('\\left\\rbrace a \\right\\lbrace'), - ` - - } - a - { + ` + + } + a + { ` )); it('rceil', () => toXmlMatch( tex2mml('\\rceil a \\lceil'), - ` - - a - + ` + + a + ` )); it('left right rceil', () => toXmlMatch( tex2mml('\\left\\rceil a \\right\\lceil'), - ` - - - a - + ` + + + a + ` )); it('rfloor', () => toXmlMatch( tex2mml('\\rfloor a \\lfloor'), - ` - - a - + ` + + a + ` )); it('left right rfloor', () => toXmlMatch( tex2mml('\\left\\rfloor a \\right\\lfloor'), - ` - - - a - + ` + + + a + ` )); it('lbrack', () => toXmlMatch( tex2mml('\\lbrack a \\rbrack'), - ` - [ - a - ] + ` + [ + a + ] ` )); it('left right lbrack', () => toXmlMatch( tex2mml('\\left\\lbrack a \\right\\rbrack'), - ` - - [ - a - ] + ` + + [ + a + ] ` )); @@ -5361,9 +5315,7 @@ describe('Named Functions', () => { tex2mml('\\sin\\quad x'), ` sin - - - + x ` )); @@ -5372,9 +5324,7 @@ describe('Named Functions', () => { tex2mml('\\sin\\! x'), ` sin - - - + x ` )); @@ -5401,211 +5351,211 @@ describe('Named Functions', () => { it('arcsin', () => toXmlMatch( tex2mml('\\arcsin'), - ` - arcsin + ` + arcsin ` )); it('arccos', () => toXmlMatch( tex2mml('\\arccos'), - ` - arccos + ` + arccos ` )); it('arctan', () => toXmlMatch( tex2mml('\\arctan'), - ` - arctan + ` + arctan ` )); it('arg', () => toXmlMatch( tex2mml('\\arg'), - ` - arg + ` + arg ` )); it('cos', () => toXmlMatch( tex2mml('\\cos'), - ` - cos + ` + cos ` )); it('cosh', () => toXmlMatch( tex2mml('\\cosh'), - ` - cosh + ` + cosh ` )); it('cot', () => toXmlMatch( tex2mml('\\cot'), - ` - cot + ` + cot ` )); it('coth', () => toXmlMatch( tex2mml('\\coth'), - ` - coth + ` + coth ` )); it('csc', () => toXmlMatch( tex2mml('\\csc'), - ` - csc + ` + csc ` )); it('deg', () => toXmlMatch( tex2mml('\\deg'), - ` - deg + ` + deg ` )); it('det', () => toXmlMatch( tex2mml('\\det'), - ` - det + ` + det ` )); it('dim', () => toXmlMatch( tex2mml('\\dim'), - ` - dim + ` + dim ` )); it('exp', () => toXmlMatch( tex2mml('\\exp'), - ` - exp + ` + exp ` )); it('gcd', () => toXmlMatch( tex2mml('\\gcd'), - ` - gcd + ` + gcd ` )); it('hom', () => toXmlMatch( tex2mml('\\hom'), - ` - hom + ` + hom ` )); it('inf', () => toXmlMatch( tex2mml('\\inf'), - ` - inf + ` + inf ` )); it('ker', () => toXmlMatch( tex2mml('\\ker'), - ` - ker + ` + ker ` )); it('lg', () => toXmlMatch( tex2mml('\\lg'), - ` - lg + ` + lg ` )); it('liminf', () => toXmlMatch( tex2mml('\\liminf'), - ` - lim inf + ` + lim inf ` )); it('limsup', () => toXmlMatch( tex2mml('\\limsup'), - ` - lim sup + ` + lim sup ` )); it('ln', () => toXmlMatch( tex2mml('\\ln'), - ` - ln + ` + ln ` )); it('log', () => toXmlMatch( tex2mml('\\log'), - ` - log + ` + log ` )); it('max', () => toXmlMatch( tex2mml('\\max'), - ` - max + ` + max ` )); it('min', () => toXmlMatch( tex2mml('\\min'), - ` - min + ` + min ` )); it('Pr', () => toXmlMatch( tex2mml('\\Pr'), - ` - Pr + ` + Pr ` )); it('sec', () => toXmlMatch( tex2mml('\\sec'), - ` - sec + ` + sec ` )); it('sinh', () => toXmlMatch( tex2mml('\\sinh'), - ` - sinh + ` + sinh ` )); it('sup', () => toXmlMatch( tex2mml('\\sup'), - ` - sup + ` + sup ` )); it('tan', () => toXmlMatch( tex2mml('\\tan'), - ` - tan + ` + tan ` )); it('tanh', () => toXmlMatch( tex2mml('\\tanh'), - ` - tanh + ` + tanh ` )); }); @@ -5628,211 +5578,211 @@ describe('Greek characters', () => { it('delta', () => toXmlMatch( tex2mml('\\delta'), - ` - δ + ` + δ ` )); it('epsilon', () => toXmlMatch( tex2mml('\\epsilon'), - ` - ϵ + ` + ϵ ` )); it('zeta', () => toXmlMatch( tex2mml('\\zeta'), - ` - ζ + ` + ζ ` )); it('eta', () => toXmlMatch( tex2mml('\\eta'), - ` - η + ` + η ` )); it('theta', () => toXmlMatch( tex2mml('\\theta'), - ` - θ + ` + θ ` )); it('iota', () => toXmlMatch( tex2mml('\\iota'), - ` - ι + ` + ι ` )); it('kappa', () => toXmlMatch( tex2mml('\\kappa'), - ` - κ + ` + κ ` )); it('lambda', () => toXmlMatch( tex2mml('\\lambda'), - ` - λ + ` + λ ` )); it('nu', () => toXmlMatch( tex2mml('\\nu'), - ` - ν + ` + ν ` )); it('xi', () => toXmlMatch( tex2mml('\\xi'), - ` - ξ + ` + ξ ` )); it('omicron', () => toXmlMatch( tex2mml('\\omicron'), - ` - ο + ` + ο ` )); it('rho', () => toXmlMatch( tex2mml('\\rho'), - ` - ρ + ` + ρ ` )); it('tau', () => toXmlMatch( tex2mml('\\tau'), - ` - τ + ` + τ ` )); it('upsilon', () => toXmlMatch( tex2mml('\\upsilon'), - ` - υ + ` + υ ` )); it('chi', () => toXmlMatch( tex2mml('\\chi'), - ` - χ + ` + χ ` )); it('psi', () => toXmlMatch( tex2mml('\\psi'), - ` - ψ + ` + ψ ` )); it('omega', () => toXmlMatch( tex2mml('\\omega'), - ` - ω + ` + ω ` )); it('varepsilon', () => toXmlMatch( tex2mml('\\varepsilon'), - ` - ε + ` + ε ` )); it('vartheta', () => toXmlMatch( tex2mml('\\vartheta'), - ` - ϑ + ` + ϑ ` )); it('varpi', () => toXmlMatch( tex2mml('\\varpi'), - ` - ϖ + ` + ϖ ` )); it('varrho', () => toXmlMatch( tex2mml('\\varrho'), - ` - ϱ + ` + ϱ ` )); it('varsigma', () => toXmlMatch( tex2mml('\\varsigma'), - ` - ς + ` + ς ` )); it('varphi', () => toXmlMatch( tex2mml('\\varphi'), - ` - φ + ` + φ ` )); it('Delta', () => toXmlMatch( tex2mml('\\Delta'), - ` - Δ + ` + Δ ` )); it('Theta', () => toXmlMatch( tex2mml('\\Theta'), - ` - Θ + ` + Θ ` )); it('Xi', () => toXmlMatch( tex2mml('\\Xi'), - ` - Ξ + ` + Ξ ` )); it('Pi', () => toXmlMatch( tex2mml('\\Pi'), - ` - Π + ` + Π ` )); it('Sigma', () => toXmlMatch( tex2mml('\\Sigma'), - ` - Σ + ` + Σ ` )); it('Phi', () => toXmlMatch( tex2mml('\\Phi'), - ` - Φ + ` + Φ ` )); it('Psi', () => toXmlMatch( tex2mml('\\Psi'), - ` - Ψ + ` + Ψ ` )); }); @@ -5841,197 +5791,197 @@ describe('Mathchar0mi', () => { it('AA', () => toXmlMatch( tex2mml('\\AA'), - ` - + ` + ` )); it('S', () => toXmlMatch( tex2mml('\\S'), - ` - § + ` + § ` )); it('aleph', () => toXmlMatch( tex2mml('\\aleph'), - ` - + ` + ` )); it('hbar', () => toXmlMatch( tex2mml('\\hbar'), - ` - + ` + ` )); it('imath', () => toXmlMatch( tex2mml('\\imath'), - ` - ı + ` + ı ` )); it('jmath', () => toXmlMatch( tex2mml('\\jmath'), - ` - ȷ + ` + ȷ ` )); it('ell', () => toXmlMatch( tex2mml('\\ell'), - ` - + ` + ` )); it('wp', () => toXmlMatch( tex2mml('\\wp'), - ` - + ` + ` )); it('Re', () => toXmlMatch( tex2mml('\\Re'), - ` - + ` + ` )); it('Im', () => toXmlMatch( tex2mml('\\Im'), - ` - + ` + ` )); it('partial', () => toXmlMatch( tex2mml('\\partial'), - ` - + ` + ` )); it('emptyset', () => toXmlMatch( tex2mml('\\emptyset'), - ` - + ` + ` )); it('nabla', () => toXmlMatch( tex2mml('\\nabla'), - ` - + ` + ` )); it('top', () => toXmlMatch( tex2mml('\\top'), - ` - + ` + ` )); it('bot', () => toXmlMatch( tex2mml('\\bot'), - ` - + ` + ` )); it('angle', () => toXmlMatch( tex2mml('\\angle'), - ` - + ` + ` )); it('triangle', () => toXmlMatch( tex2mml('\\triangle'), - ` - + ` + ` )); it('forall', () => toXmlMatch( tex2mml('\\forall'), - ` - + ` + ` )); it('exists', () => toXmlMatch( tex2mml('\\exists'), - ` - + ` + ` )); it('neg', () => toXmlMatch( tex2mml('\\neg'), - ` - ¬ + ` + ¬ ` )); it('lnot', () => toXmlMatch( tex2mml('\\lnot'), - ` - ¬ + ` + ¬ ` )); it('flat', () => toXmlMatch( tex2mml('\\flat'), - ` - + ` + ` )); it('natural', () => toXmlMatch( tex2mml('\\natural'), - ` - + ` + ` )); it('sharp', () => toXmlMatch( tex2mml('\\sharp'), - ` - + ` + ` )); it('clubsuit', () => toXmlMatch( tex2mml('\\clubsuit'), - ` - + ` + ` )); it('diamondsuit', () => toXmlMatch( tex2mml('\\diamondsuit'), - ` - + ` + ` )); it('heartsuit', () => toXmlMatch( tex2mml('\\heartsuit'), - ` - + ` + ` )); it('spadesuit', () => toXmlMatch( tex2mml('\\spadesuit'), - ` - + ` + ` )); }); @@ -6047,45 +5997,45 @@ describe('Mathchar0mo', () => { it('surd', () => toXmlMatch( tex2mml('\\surd'), - ` - - + ` + + ` )); it('coprod', () => toXmlMatch( tex2mml('\\coprod'), - ` - + ` + ` )); it('bigvee', () => toXmlMatch( tex2mml('\\bigvee'), - ` - + ` + ` )); it('bigwedge', () => toXmlMatch( tex2mml('\\bigwedge'), - ` - + ` + ` )); it('biguplus', () => toXmlMatch( tex2mml('\\biguplus'), - ` - + ` + ` )); it('bigcap', () => toXmlMatch( tex2mml('\\bigcap'), - ` - + ` + ` )); it('bigcup', () => @@ -6098,729 +6048,729 @@ describe('Mathchar0mo', () => { it('intop', () => toXmlMatch( tex2mml('\\intop'), - ` - + ` + ` )); it('iint', () => toXmlMatch( tex2mml('\\iint'), - ` - + ` + ` )); it('iiint', () => toXmlMatch( tex2mml('\\iiint'), - ` - + ` + ` )); it('bigotimes', () => toXmlMatch( tex2mml('\\bigotimes'), - ` - + ` + ` )); it('bigoplus', () => toXmlMatch( tex2mml('\\bigoplus'), - ` - + ` + ` )); it('bigodot', () => toXmlMatch( tex2mml('\\bigodot'), - ` - + ` + ` )); it('ointop', () => toXmlMatch( tex2mml('\\ointop'), - ` - + ` + ` )); it('oiint', () => toXmlMatch( tex2mml('\\oiint'), - ` - + ` + ` )); it('oiiint', () => toXmlMatch( tex2mml('\\oiiint'), - ` - + ` + ` )); it('bigsqcup', () => toXmlMatch( tex2mml('\\bigsqcup'), - ` - + ` + ` )); it('smallint', () => toXmlMatch( tex2mml('\\smallint'), - ` - + ` + ` )); it('triangleleft', () => toXmlMatch( tex2mml('\\triangleleft'), - ` - + ` + ` )); it('triangleright', () => toXmlMatch( tex2mml('\\triangleright'), - ` - + ` + ` )); it('bigtriangleup', () => toXmlMatch( tex2mml('\\bigtriangleup'), - ` - + ` + ` )); it('bigtriangledown', () => toXmlMatch( tex2mml('\\bigtriangledown'), - ` - + ` + ` )); it('wedge', () => toXmlMatch( tex2mml('\\wedge'), - ` - + ` + ` )); it('land', () => toXmlMatch( tex2mml('\\land'), - ` - + ` + ` )); it('vee', () => toXmlMatch( tex2mml('\\vee'), - ` - + ` + ` )); it('lor', () => toXmlMatch( tex2mml('\\lor'), - ` - + ` + ` )); it('cap', () => toXmlMatch( tex2mml('\\cap'), - ` - + ` + ` )); it('cup', () => toXmlMatch( tex2mml('\\cup'), - ` - + ` + ` )); it('ddagger', () => toXmlMatch( tex2mml('\\ddagger'), - ` - + ` + ` )); it('dagger', () => toXmlMatch( tex2mml('\\dagger'), - ` - + ` + ` )); it('sqcap', () => toXmlMatch( tex2mml('\\sqcap'), - ` - + ` + ` )); it('sqcup', () => toXmlMatch( tex2mml('\\sqcup'), - ` - + ` + ` )); it('uplus', () => toXmlMatch( tex2mml('\\uplus'), - ` - + ` + ` )); it('amalg', () => toXmlMatch( tex2mml('\\amalg'), - ` - ⨿ + ` + ⨿ ` )); it('diamond', () => toXmlMatch( tex2mml('\\diamond'), - ` - + ` + ` )); it('bullet', () => toXmlMatch( tex2mml('\\bullet'), - ` - + ` + ` )); it('wr', () => toXmlMatch( tex2mml('\\wr'), - ` - + ` + ` )); it('div', () => toXmlMatch( tex2mml('\\div'), - ` - ÷ + ` + ÷ ` )); it('odot', () => toXmlMatch( tex2mml('\\odot'), - ` - + ` + ` )); it('oslash', () => toXmlMatch( tex2mml('\\oslash'), - ` - + ` + ` )); it('otimes', () => toXmlMatch( tex2mml('\\otimes'), - ` - + ` + ` )); it('ominus', () => toXmlMatch( tex2mml('\\ominus'), - ` - + ` + ` )); it('oplus', () => toXmlMatch( tex2mml('\\oplus'), - ` - + ` + ` )); it('mp', () => toXmlMatch( tex2mml('\\mp'), - ` - + ` + ` )); it('circ', () => toXmlMatch( tex2mml('\\circ'), - ` - + ` + ` )); it('bigcirc', () => toXmlMatch( tex2mml('\\bigcirc'), - ` - + ` + ` )); it('setminus', () => toXmlMatch( tex2mml('\\setminus'), - ` - + ` + ` )); it('cdot', () => toXmlMatch( tex2mml('\\cdot'), - ` - + ` + ` )); it('ast', () => toXmlMatch( tex2mml('\\ast'), - ` - + ` + ` )); it('times', () => toXmlMatch( tex2mml('\\times'), - ` - × + ` + × ` )); it('star', () => toXmlMatch( tex2mml('\\star'), - ` - + ` + ` )); it('propto', () => toXmlMatch( tex2mml('\\propto'), - ` - + ` + ` )); it('sqsubseteq', () => toXmlMatch( tex2mml('\\sqsubseteq'), - ` - + ` + ` )); it('sqsupseteq', () => toXmlMatch( tex2mml('\\sqsupseteq'), - ` - + ` + ` )); it('parallel', () => toXmlMatch( tex2mml('\\parallel'), - ` - + ` + ` )); it('mid', () => toXmlMatch( tex2mml('\\mid'), - ` - + ` + ` )); it('dashv', () => toXmlMatch( tex2mml('\\dashv'), - ` - + ` + ` )); it('vdash', () => toXmlMatch( tex2mml('\\vdash'), - ` - + ` + ` )); it('le', () => toXmlMatch( tex2mml('\\le'), - ` - + ` + ` )); it('geq', () => toXmlMatch( tex2mml('\\geq'), - ` - + ` + ` )); it('ge', () => toXmlMatch( tex2mml('\\ge'), - ` - + ` + ` )); it('succ', () => toXmlMatch( tex2mml('\\succ'), - ` - + ` + ` )); it('prec', () => toXmlMatch( tex2mml('\\prec'), - ` - + ` + ` )); it('approx', () => toXmlMatch( tex2mml('\\approx'), - ` - + ` + ` )); it('succeq', () => toXmlMatch( tex2mml('\\succeq'), - ` - + ` + ` )); it('preceq', () => toXmlMatch( tex2mml('\\preceq'), - ` - + ` + ` )); it('supset', () => toXmlMatch( tex2mml('\\supset'), - ` - + ` + ` )); it('subset', () => toXmlMatch( tex2mml('\\subset'), - ` - + ` + ` )); it('supseteq', () => toXmlMatch( tex2mml('\\supseteq'), - ` - + ` + ` )); it('subseteq', () => toXmlMatch( tex2mml('\\subseteq'), - ` - + ` + ` )); it('in', () => toXmlMatch( tex2mml('\\in'), - ` - + ` + ` )); it('ni', () => toXmlMatch( tex2mml('\\ni'), - ` - + ` + ` )); it('notin', () => toXmlMatch( tex2mml('\\notin'), - ` - + ` + ` )); it('owns', () => toXmlMatch( tex2mml('\\owns'), - ` - + ` + ` )); it('gg', () => toXmlMatch( tex2mml('\\gg'), - ` - + ` + ` )); it('ll', () => toXmlMatch( tex2mml('\\ll'), - ` - + ` + ` )); it('perp', () => toXmlMatch( tex2mml('\\perp'), - ` - + ` + ` )); it('equiv', () => toXmlMatch( tex2mml('\\equiv'), - ` - + ` + ` )); it('smile', () => toXmlMatch( tex2mml('\\smile'), - ` - + ` + ` )); it('frown', () => toXmlMatch( tex2mml('\\frown'), - ` - + ` + ` )); it('ne', () => toXmlMatch( tex2mml('\\ne'), - ` - + ` + ` )); it('neq', () => toXmlMatch( tex2mml('\\neq'), - ` - + ` + ` )); it('doteq', () => toXmlMatch( tex2mml('\\doteq'), - ` - + ` + ` )); it('bowtie', () => toXmlMatch( tex2mml('\\bowtie'), - ` - + ` + ` )); it('models', () => toXmlMatch( tex2mml('\\models'), - ` - + ` + ` )); it('notChar', () => toXmlMatch( tex2mml('\\notChar'), - ` - + ` + ` )); it('Leftrightarrow', () => toXmlMatch( tex2mml('\\Leftrightarrow'), - ` - + ` + ` )); it('Leftarrow', () => toXmlMatch( tex2mml('\\Leftarrow'), - ` - + ` + ` )); it('leftrightarrow', () => toXmlMatch( tex2mml('\\leftrightarrow'), - ` - + ` + ` )); it('leftarrow', () => toXmlMatch( tex2mml('\\leftarrow'), - ` - + ` + ` )); it('gets', () => toXmlMatch( tex2mml('\\gets'), - ` - + ` + ` )); it('to', () => toXmlMatch( tex2mml('\\to'), - ` - + ` + ` )); it('mapsto', () => toXmlMatch( tex2mml('\\mapsto'), - ` - + ` + ` )); it('leftharpoonup', () => toXmlMatch( tex2mml('\\leftharpoonup'), - ` - + ` + ` )); it('leftharpoondown', () => toXmlMatch( tex2mml('\\leftharpoondown'), - ` - + ` + ` )); it('rightharpoonup', () => toXmlMatch( tex2mml('\\rightharpoonup'), - ` - + ` + ` )); it('rightharpoondown', () => toXmlMatch( tex2mml('\\rightharpoondown'), - ` - + ` + ` )); it('nearrow', () => toXmlMatch( tex2mml('\\nearrow'), - ` - + ` + ` )); it('searrow', () => toXmlMatch( tex2mml('\\searrow'), - ` - + ` + ` )); it('nwarrow', () => toXmlMatch( tex2mml('\\nwarrow'), - ` - + ` + ` )); it('swarrow', () => toXmlMatch( tex2mml('\\swarrow'), - ` - + ` + ` )); it('rightleftharpoons', () => toXmlMatch( tex2mml('\\rightleftharpoons'), - ` - + ` + ` )); it('hookrightarrow', () => toXmlMatch( tex2mml('\\hookrightarrow'), - ` - + ` + ` )); it('hookleftarrow', () => toXmlMatch( tex2mml('\\hookleftarrow'), - ` - + ` + ` )); it('longleftarrow', () => toXmlMatch( tex2mml('\\longleftarrow'), - ` - + ` + ` )); it('Longleftarrow', () => toXmlMatch( tex2mml('\\Longleftarrow'), - ` - + ` + ` )); it('Longrightarrow', () => toXmlMatch( tex2mml('\\Longrightarrow'), - ` - + ` + ` )); it('Longleftrightarrow', () => toXmlMatch( tex2mml('\\Longleftrightarrow'), - ` - + ` + ` )); it('longleftrightarrow', () => toXmlMatch( tex2mml('\\longleftrightarrow'), - ` - + ` + ` )); it('longmapsto', () => toXmlMatch( tex2mml('\\longmapsto'), - ` - + ` + ` )); it('colon', () => toXmlMatch( tex2mml('\\colon'), - ` - : + ` + : ` )); }); @@ -6847,109 +6797,109 @@ describe('Dots', () => { it('Dots Left', () => toXmlMatch( tex2mml('\\dots\\left( A\\right)'), - ` + ` - - ( - A - ) + + ( + A + ) ` )); it('Dots Open', () => toXmlMatch( tex2mml('\\dots{\\alpha}'), - ` + ` - - α + + α ` )); it('ldots', () => toXmlMatch( tex2mml('\\ldots'), - ` - + ` + ` )); it('vdots', () => toXmlMatch( tex2mml('\\vdots'), - ` - - + ` + + ` )); it('cdots', () => toXmlMatch( tex2mml('\\cdots'), - ` - + ` + ` )); it('ddots', () => toXmlMatch( tex2mml('\\ddots'), - ` - + ` + ` )); it('iddots', () => toXmlMatch( tex2mml('\\iddots'), - ` - + ` + ` )); it('dotsc', () => toXmlMatch( tex2mml('\\dotsc'), - ` - + ` + ` )); it('dotsb', () => toXmlMatch( tex2mml('\\dotsb'), - ` - + ` + ` )); it('dotsm', () => toXmlMatch( tex2mml('\\dotsm'), - ` - + ` + ` )); it('dotsi', () => toXmlMatch( tex2mml('\\dotsi'), - ` - + ` + ` )); it('dotso', () => toXmlMatch( tex2mml('\\dotso'), - ` - + ` + ` )); it('ldotp', () => toXmlMatch( tex2mml('\\ldotp'), - ` - . + ` + . ` )); it('cdotp', () => toXmlMatch( tex2mml('\\cdotp'), - ` - + ` + ` )); }); @@ -6959,67 +6909,67 @@ describe('Font Simple', () => { it('rm', () => toXmlMatch( tex2mml('\\rm a'), - ` - a + ` + a ` )); it('mit', () => toXmlMatch( tex2mml('\\mit a'), - ` - a + ` + a ` )); it('oldstyle', () => toXmlMatch( tex2mml('\\oldstyle 9'), - ` - 9 + ` + 9 ` )); it('it', () => toXmlMatch( tex2mml('\\it a'), - ` - a + ` + a ` )); it('bf', () => toXmlMatch( tex2mml('\\bf a'), - ` - a + ` + a ` )); it('sf', () => toXmlMatch( tex2mml('\\sf a'), - ` - a + ` + a ` )); it('tt', () => toXmlMatch( tex2mml('\\tt a'), - ` - a + ` + a ` )); it('frak', () => toXmlMatch( tex2mml('\\frak a'), - ` - - a + ` + + a ` )); it('Bbb', () => toXmlMatch( tex2mml('\\Bbb a'), - ` - - a + ` + + a ` )); @@ -7035,410 +6985,410 @@ describe('Font Simple', () => { it('mathup', () => toXmlMatch( tex2mml('\\mathup a'), - ` - - a + ` + + a ` )); it('mathnormal', () => toXmlMatch( tex2mml('\\mathnormal a'), - ` - - a + ` + + a ` )); it('mathbfup', () => toXmlMatch( tex2mml('\\mathbfup a'), - ` - - a + ` + + a ` )); it('mathit', () => toXmlMatch( tex2mml('\\mathit a'), - ` - - a + ` + + a ` )); it('mathbfit', () => toXmlMatch( tex2mml('\\mathbfit a'), - ` - - a + ` + + a ` )); it('mathbb', () => toXmlMatch( tex2mml('\\mathbb a'), - ` - - a + ` + + a ` )); it('mathfrak', () => toXmlMatch( tex2mml('\\mathfrak a'), - ` - - a + ` + + a ` )); it('mathbffrak', () => toXmlMatch( tex2mml('\\mathbffrak a'), - ` - - a + ` + + a ` )); it('mathscr', () => toXmlMatch( tex2mml('\\mathscr a'), - ` - - a + ` + + a ` )); it('mathbfscr', () => toXmlMatch( tex2mml('\\mathbfscr a'), - ` - - a + ` + + a ` )); it('mathsf', () => toXmlMatch( tex2mml('\\mathsf a'), - ` - - a + ` + + a ` )); it('mathsfup', () => toXmlMatch( tex2mml('\\mathsfup a'), - ` - - a + ` + + a ` )); it('mathbfsf', () => toXmlMatch( tex2mml('\\mathbfsf a'), - ` - - a + ` + + a ` )); it('mathbfsfup', () => toXmlMatch( tex2mml('\\mathbfsfup a'), - ` - - a + ` + + a ` )); it('mathsfit', () => toXmlMatch( tex2mml('\\mathsfit a'), - ` - - a + ` + + a ` )); it('mathbfsfit', () => toXmlMatch( tex2mml('\\mathbfsfit a'), - ` - - a + ` + + a ` )); it('mathtt', () => toXmlMatch( tex2mml('\\mathtt a'), - ` - - a + ` + + a ` )); it('mathcal', () => toXmlMatch( tex2mml('\\mathcal a'), - ` - - a + ` + + a ` )); it('mathbfcal', () => toXmlMatch( tex2mml('\\mathbfcal a'), - ` - - a + ` + + a ` )); it('symrm', () => toXmlMatch( tex2mml('\\symrm a'), - ` - - a + ` + + a ` )); it('symup', () => toXmlMatch( tex2mml('\\symup a'), - ` - - a + ` + + a ` )); it('symnormal', () => toXmlMatch( tex2mml('\\symnormal a'), - ` - - a + ` + + a ` )); it('symbf', () => toXmlMatch( tex2mml('\\symbf a'), - ` - - a + ` + + a ` )); it('symbfup', () => toXmlMatch( tex2mml('\\symbfup a'), - ` - - a + ` + + a ` )); it('symit', () => toXmlMatch( tex2mml('\\symit a'), - ` - - a + ` + + a ` )); it('symbfit', () => toXmlMatch( tex2mml('\\symbfit a'), - ` - - a + ` + + a ` )); it('symbb', () => toXmlMatch( tex2mml('\\symbb a'), - ` - - a + ` + + a ` )); it('symfrak', () => toXmlMatch( tex2mml('\\symfrak a'), - ` - - a + ` + + a ` )); it('symbffrak', () => toXmlMatch( tex2mml('\\symbffrak a'), - ` - - a + ` + + a ` )); it('symscr', () => toXmlMatch( tex2mml('\\symscr a'), - ` - - a + ` + + a ` )); it('symbfscr', () => toXmlMatch( tex2mml('\\symbfscr a'), - ` - - a + ` + + a ` )); it('symsf', () => toXmlMatch( tex2mml('\\symsf a'), - ` - - a + ` + + a ` )); it('symsfup', () => toXmlMatch( tex2mml('\\symsfup a'), - ` - - a + ` + + a ` )); it('symbfsf', () => toXmlMatch( tex2mml('\\symbfsf a'), - ` - - a + ` + + a ` )); it('symbfsfup', () => toXmlMatch( tex2mml('\\symbfsfup a'), - ` - - a + ` + + a ` )); it('symsfit', () => toXmlMatch( tex2mml('\\symsfit a'), - ` - - a + ` + + a ` )); it('symbfsfit', () => toXmlMatch( tex2mml('\\symbfsfit a'), - ` - - a + ` + + a ` )); it('symtt', () => toXmlMatch( tex2mml('\\symtt a'), - ` - - a + ` + + a ` )); it('symcal', () => toXmlMatch( tex2mml('\\symcal a'), - ` - - a + ` + + a ` )); it('symbfcal', () => toXmlMatch( tex2mml('\\symbfcal a'), - ` - - a + ` + + a ` )); it('textrm', () => toXmlMatch( tex2mml('\\textrm a'), - ` - a + ` + a ` )); it('textup', () => toXmlMatch( tex2mml('\\textup a'), - ` - a + ` + a ` )); it('textnormal', () => toXmlMatch( tex2mml('\\textnormal a'), - ` - a + ` + a ` )); it('textit', () => toXmlMatch( tex2mml('\\textit a'), - ` - a + ` + a ` )); it('textbf', () => toXmlMatch( tex2mml('\\textbf a'), - ` - a + ` + a ` )); it('textsf', () => toXmlMatch( tex2mml('\\textsf a'), - ` - a + ` + a ` )); it('texttt', () => toXmlMatch( tex2mml('\\texttt a'), - ` - a + ` + a ` )); }); @@ -7447,11 +7397,11 @@ describe('Over Under Extenders', () => { it('overparen', () => toXmlMatch( tex2mml('\\overparen{ab}'), - ` - - - a - b + ` + + + a + b @@ -7460,11 +7410,11 @@ describe('Over Under Extenders', () => { it('underparen', () => toXmlMatch( tex2mml('\\underparen{ab}'), - ` - - - a - b + ` + + + a + b @@ -7473,11 +7423,11 @@ describe('Over Under Extenders', () => { it('overrightarrow', () => toXmlMatch( tex2mml('\\overrightarrow{ab}'), - ` - - - a - b + ` + + + a + b @@ -7486,11 +7436,11 @@ describe('Over Under Extenders', () => { it('underrightarrow', () => toXmlMatch( tex2mml('\\underrightarrow{ab}'), - ` - - - a - b + ` + + + a + b @@ -7499,11 +7449,11 @@ describe('Over Under Extenders', () => { it('overleftarrow', () => toXmlMatch( tex2mml('\\overleftarrow{ab}'), - ` - - - a - b + ` + + + a + b @@ -7512,11 +7462,11 @@ describe('Over Under Extenders', () => { it('underleftarrow', () => toXmlMatch( tex2mml('\\underleftarrow{ab}'), - ` - - - a - b + ` + + + a + b @@ -7525,11 +7475,11 @@ describe('Over Under Extenders', () => { it('overleftrightarrow', () => toXmlMatch( tex2mml('\\overleftrightarrow{ab}'), - ` - - - a - b + ` + + + a + b @@ -7541,27 +7491,25 @@ describe('Math style sizes', () => { it('displaystyle', () => toXmlMatch( tex2mml('\\displaystyle A', false), - ` - - A + ` + + A ` )); it('textstyle', () => toXmlMatch( tex2mml('\\textstyle B', false), - ` - - B - + ` + B ` )); it('scriptstyle', () => toXmlMatch( tex2mml('\\scriptstyle C', false), - ` - - C + ` + + C ` )); @@ -7580,53 +7528,53 @@ describe('Special characters', () => { it('Space', () => toXmlMatch( tex2mml('a b'), - ` - a - b + ` + a + b ` )); it('Tab', () => toXmlMatch( tex2mml('a\tb'), - ` - a - b + ` + a + b ` )); it('CR', () => toXmlMatch( tex2mml('a\rb'), - ` - a - b + ` + a + b ` )); it('Newline', () => toXmlMatch( tex2mml('a\nb'), - ` - a - b + ` + a + b ` )); it('No break space', () => toXmlMatch( tex2mml('a{\u00A0}b'), - ` - a - - b + ` + a + + b ` )); it('Prime', () => toXmlMatch( tex2mml('a\u2019b'), - ` + ` - a - + a + - b + b ` )); }); @@ -7635,107 +7583,103 @@ describe('Special macros', () => { it('Iff', () => toXmlMatch( tex2mml('A \\iff B'), - ` - A - - - - - - - - B + ` + A + + + + B ` )); it('TeX', () => toXmlMatch( tex2mml('\\TeX'), - ` - T - - - - E + ` + T + + + + E - - X + + X ` )); it('LaTeX', () => toXmlMatch( tex2mml('\\LaTeX'), - ` - L - - - - - - A + ` + L + + + + + + A - - T - - - - E + + T + + + + E - - X + + X ` )); it('Skew 7', () => toXmlMatch( tex2mml('\\skew7\\hat A'), - ` - - - + ` + + + - - A - + + A + - ^ + ^ - + - + ` )); it('Skew 20', () => toXmlMatch( tex2mml('\\skew{20}\\hat A'), - ` - - - + ` + + + - - A - + + A + - ^ + ^ - + - + ` )); it('Pmb', () => toXmlMatch( tex2mml('a \\pmb a \\boldsymbol a'), - ` - + ` + Undefined control sequence \\boldsymbol ` @@ -7743,28 +7687,28 @@ describe('Special macros', () => { it('Space', () => toXmlMatch( tex2mml('A \\space B'), - ` - A -   - B + ` + A +   + B ` )); it('Space 2', () => toXmlMatch( tex2mml('A \\ B'), - ` - A + ` + A   - B + B ` )); it('Space 3', () => toXmlMatch( tex2mml('A \\ B'), - ` - A + ` + A   - B + B ` )); }); @@ -7773,90 +7717,90 @@ describe('Big Commands for Delimiters', () => { it('big', () => toXmlMatch( tex2mml('\\big|'), - ` - - | + ` + + | ` )); it('Big', () => toXmlMatch( tex2mml('\\Big|'), - ` - - | + ` + + | ` )); it('bigg', () => toXmlMatch( tex2mml('\\bigg|'), - ` - - | + ` + + | ` )); it('Bigg', () => toXmlMatch( tex2mml('\\Bigg|'), - ` - - | + ` + + | ` )); it('Biggl', () => toXmlMatch( tex2mml('\\Biggl|'), - ` - - | + ` + + | ` )); it('Biggr', () => toXmlMatch( tex2mml('\\Biggr|'), - ` - - | + ` + + | ` )); it('bigm', () => toXmlMatch( tex2mml('\\bigm|'), - ` - - | + ` + + | ` )); it('Bigm', () => toXmlMatch( tex2mml('\\Bigm|'), - ` - - | + ` + + | ` )); it('biggm', () => toXmlMatch( tex2mml('\\biggm|'), - ` - - | + ` + + | ` )); it('Biggm', () => toXmlMatch( tex2mml('\\Biggm|'), - ` - - | + ` + + | ` )); @@ -7876,7 +7820,7 @@ describe('Boxes', () => { toXmlMatch( tex2mml('\\hbox{x}'), ` - + x ` @@ -7884,71 +7828,71 @@ describe('Boxes', () => { it('Vtop', () => toXmlMatch( tex2mml('\\vtop{x}'), - ` - - x + ` + + x ` )); it('Vtop Hsize', () => toXmlMatch( tex2mml('\\hsize{2cm}\\vtop{x}'), - ` - - x + ` + + x ` )); it('Vtop Hsize =', () => toXmlMatch( tex2mml('\\hsize=2cm\\vtop{x}'), - ` - - x + ` + + x ` )); it('Vcenter', () => toXmlMatch( tex2mml('\\vcenter{x}'), - ` - - x + ` + + x ` )); it('Vcenter Hsize', () => toXmlMatch( tex2mml('\\hsize{2cm}\\vcenter{x}'), - ` - - x + ` + + x ` )); it('Vbox', () => toXmlMatch( tex2mml('\\vbox{x}'), - ` - - x + ` + + x ` )); it('Vbox Hsize', () => toXmlMatch( tex2mml('\\hsize{2cm}\\vbox{x}'), - ` - - x + ` + + x ` )); it('Parbox', () => toXmlMatch( tex2mml('\\parbox{2cm}{x}'), - ` - + ` + x ` @@ -7956,14 +7900,12 @@ describe('Boxes', () => { it('Boxed', () => toXmlMatch( tex2mml('\\boxed{x}'), - ` - - - - - x - - + ` + + + + x + ` @@ -7971,9 +7913,9 @@ describe('Boxes', () => { it('Framebox', () => toXmlMatch( tex2mml('\\framebox{x}'), - ` - - + ` + + x @@ -7982,10 +7924,10 @@ describe('Boxes', () => { it('Framebox dimension', () => toXmlMatch( tex2mml('\\framebox[2cm]{x}'), - ` - - - + ` + + + x @@ -7995,10 +7937,10 @@ describe('Boxes', () => { it('Framebox dimension position', () => toXmlMatch( tex2mml('\\framebox[2cm][c]{x}'), - ` - - - + ` + + + x @@ -8008,8 +7950,8 @@ describe('Boxes', () => { it('Makebox', () => toXmlMatch( tex2mml('\\makebox{x}'), - ` - + ` + x ` @@ -8017,8 +7959,8 @@ describe('Boxes', () => { it('Makebox dimension', () => toXmlMatch( tex2mml('\\makebox[2cm]{x}'), - ` - + ` + x ` @@ -8026,8 +7968,8 @@ describe('Boxes', () => { it('Makebox dimension position', () => toXmlMatch( tex2mml('\\makebox[2cm][c]{x}'), - ` - + ` + x ` @@ -8035,8 +7977,8 @@ describe('Boxes', () => { it('Makebox Cap position', () => toXmlMatch( tex2mml('\\makebox[2cm][C]{x}'), - ` - + ` + x ` @@ -8051,18 +7993,18 @@ describe('Boxes', () => { it('Rule 2D positive raise', () => toXmlMatch( tex2mml('\\rule[3cm]{2cm}{1cm}'), - ` - - + ` + + ` )); it('Rule 2D negative raise', () => toXmlMatch( tex2mml('\\rule[-3cm]{2cm}{1cm}'), - ` - - + ` + + ` )); @@ -8201,9 +8143,7 @@ describe('Moving Elements', () => { - - - + / @@ -8230,9 +8170,7 @@ describe('Moving Elements', () => { / - - - + @@ -8316,64 +8254,64 @@ describe('Moving Elements', () => { it('Moveright', () => toXmlMatch( tex2mml('\\moveright 1em {x}'), - ` - - - x + ` + + + x - + ` )); it('Moveleft', () => toXmlMatch( tex2mml('\\moveleft 1em {x}'), - ` - - - x + ` + + + x - + ` )); it('Move Left Negative', () => toXmlMatch( tex2mml('x\\moveleft -2pt {y} z'), - ` - x - - - y + ` + x + + + y - - z + + z ` )); it('Move Right Negative', () => toXmlMatch( tex2mml('x\\moveright -2pt {y} z'), - ` - x - - - y + ` + x + + + y - - z + + z ` )); it('Mathstrut', () => toXmlMatch( tex2mml('\\mathstrut{x}'), - ` - - + ` + + - ( + ( - - x + + x ` )); @@ -8455,135 +8393,135 @@ describe('Linebreaks', () => { it('allowbreak', () => toXmlMatch( tex2mml('a\\allowbreak b'), - ` - a - - b + ` + a + + b ` )); it('allowbreak cdot', () => toXmlMatch( tex2mml('a\\allowbreak \cdot b'), - ` - a - - c - d - o - t - b + ` + a + + c + d + o + t + b ` )); it('goodbreak', () => toXmlMatch( tex2mml('a\\goodbreak b'), - ` - a - - b + ` + a + + b ` )); it('goodbreak cdot', () => toXmlMatch( tex2mml('a\\goodbreak\\cdot b'), - ` - a - - b + ` + a + + b ` )); it('goodbreak cdot cdot', () => toXmlMatch( tex2mml('a\\cdot\\goodbreak\\cdot b'), - ` - a - - - b + ` + a + + + b ` )); it('goodbreak comma cdot', () => toXmlMatch( tex2mml('a,\\goodbreak\\cdot b'), - ` - a - , - - b + ` + a + , + + b ` )); it('badbreak', () => toXmlMatch( tex2mml('a\\badbreak b'), - ` - a - - b + ` + a + + b ` )); it('badbreak cdot', () => toXmlMatch( tex2mml('a\\badbreak\\cdot b'), - ` - a - - b + ` + a + + b ` )); it('nobreak', () => toXmlMatch( tex2mml('a\\nobreak b'), - ` - a - - b + ` + a + + b ` )); it('nobreak cdot', () => toXmlMatch( tex2mml('a\\nobreak\\cdot b'), - ` - a - - b + ` + a + + b ` )); it('break', () => toXmlMatch( tex2mml('a\\break b'), - ` - a - - b + ` + a + + b ` )); it('newline', () => toXmlMatch( tex2mml('a\\newline b'), - ` - a - - b + ` + a + + b ` )); it('goodbreak comma', () => toXmlMatch( tex2mml('a,\\goodbreak b'), - ` - a - , - - b + ` + a + , + + b ` )); it('goodbreak comma comma', () => toXmlMatch( tex2mml('a,\\goodbreak, b'), - ` - a - , - , - b + ` + a + , + , + b ` )); }); @@ -8644,37 +8582,37 @@ describe('MathChar7', () => { it('Underscore', () => toXmlMatch( tex2mml('a\\_b'), - ` - a - _ - b + ` + a + _ + b ` )); it('Hash', () => toXmlMatch( tex2mml('a\\#b'), - ` - a - # - b + ` + a + # + b ` )); it('Dollar', () => toXmlMatch( tex2mml('a\\$b'), - ` - a - $ - b + ` + a + $ + b ` )); it('Percentage', () => toXmlMatch( tex2mml('a\\%b'), - ` - a - % - b + ` + a + % + b ` )); }); @@ -8726,11 +8664,11 @@ describe('Accents', () => { it('acute', () => toXmlMatch( tex2mml('\\acute{a}'), - ` - + ` + - a - ´ + a + ´ ` @@ -8738,11 +8676,11 @@ describe('Accents', () => { it('grave', () => toXmlMatch( tex2mml('\\grave{a}'), - ` - + ` + - a - \` + a + \` ` @@ -8750,10 +8688,10 @@ describe('Accents', () => { it('ddot', () => toXmlMatch( tex2mml('\\ddot{a}'), - ` - + ` + - a + a ¨ @@ -8762,10 +8700,10 @@ describe('Accents', () => { it('dddot', () => toXmlMatch( tex2mml('\\dddot{a}'), - ` - + ` + - a + a @@ -8774,10 +8712,10 @@ describe('Accents', () => { it('ddddot', () => toXmlMatch( tex2mml('\\ddddot{a}'), - ` - + ` + - a + a @@ -8786,11 +8724,11 @@ describe('Accents', () => { it('tilde', () => toXmlMatch( tex2mml('\\tilde{a}'), - ` - + ` + - a - ~ + a + ~ ` @@ -8798,11 +8736,11 @@ describe('Accents', () => { it('bar', () => toXmlMatch( tex2mml('\\bar{a}'), - ` - + ` + - a - ¯ + a + ¯ ` @@ -8810,10 +8748,10 @@ describe('Accents', () => { it('breve', () => toXmlMatch( tex2mml('\\breve{a}'), - ` - + ` + - a + a ˘ @@ -8822,11 +8760,11 @@ describe('Accents', () => { it('check', () => toXmlMatch( tex2mml('\\check{a}'), - ` - + ` + - a - ˇ + a + ˇ ` @@ -8834,11 +8772,11 @@ describe('Accents', () => { it('hat', () => toXmlMatch( tex2mml('\\hat{a}'), - ` - + ` + - a - ^ + a + ^ ` @@ -8846,10 +8784,10 @@ describe('Accents', () => { it('dot', () => toXmlMatch( tex2mml('\\dot{a}'), - ` - + ` + - a + a ˙ @@ -8858,13 +8796,13 @@ describe('Accents', () => { it('widetilde', () => toXmlMatch( tex2mml('\\widetilde{abc}'), - ` - + ` + - - a - b - c + + a + b + c ~ @@ -8874,13 +8812,13 @@ describe('Accents', () => { it('widehat', () => toXmlMatch( tex2mml('\\widehat{abc}'), - ` - + ` + - - a - b - c + + a + b + c ^ @@ -8951,67 +8889,67 @@ describe('Character Class Changes', () => { it('mathord', () => toXmlMatch( tex2mml('a\\mathord{b}c'), - ` - a - - b + ` + a + + b - c + c ` )); it('mathopen', () => toXmlMatch( tex2mml('a\\mathopen{b}c'), - ` - a - - b + ` + a + + b - c + c ` )); it('mathclose', () => toXmlMatch( tex2mml('a\\mathclose{b}c'), - ` - a - - b + ` + a + + b - c + c ` )); it('mathbin', () => toXmlMatch( tex2mml('a\\mathbin{b}c'), - ` - a - - b + ` + a + + b - c + c ` )); it('mathpunct', () => toXmlMatch( tex2mml('a\\mathpunct{b}c'), - ` - a - - b + ` + a + + b - c + c ` )); it('mathinner', () => toXmlMatch( tex2mml('a\\mathinner{b}c'), - ` - a - - b + ` + a + + b - c + c ` )); }); @@ -9021,39 +8959,35 @@ describe('Spacing', () => { it('Nonscript toplevel', () => toXmlMatch( tex2mml('\\left. a \\nonscript\\;\\middle|\\nonscript\\; b \\right.'), - ` - - - a - - - - - | - - - - - b - + ` + + + a + + + | + + + b + ` )); it('Nonscript scriptlevel', () => toXmlMatch( tex2mml('X_{\\left. a \\nonscript\\;\\middle|\\nonscript\\; b \\right.}'), - ` - - X - - - - a - - | - - b - + ` + + X + + + + a + + | + + b + @@ -9062,36 +8996,36 @@ describe('Spacing', () => { it('hskip', () => toXmlMatch( tex2mml('\\hskip{1cm}'), - ` - + ` + ` )); it('hspace', () => toXmlMatch( tex2mml('\\hspace{1cm}'), - ` - + ` + ` )); it('mskip', () => toXmlMatch( tex2mml('\\mskip{1cm}'), - ` - + ` + ` )); it('mspace', () => toXmlMatch( tex2mml('\\mspace{1cm}'), - ` - + ` + ` )); it('mkern', () => toXmlMatch( tex2mml('\\mkern{1cm}'), - ` - + ` + ` )); }); @@ -9101,17 +9035,17 @@ describe('Complete Base Methods', () => { it('Comment', () => toXmlMatch( tex2mml('a %comment'), - ` - a + ` + a ` )); it('Elided Times', () => toXmlMatch( tex2mml('a\\* b'), - ` - a - - b + ` + a + + b ` )); }); @@ -9123,14 +9057,14 @@ describe('Referencing', () => { it('Label', () => toXmlMatch( tex2mml('a\\label{A}'), - ` - + ` + - - (1) + + (1) - a + a @@ -9139,14 +9073,14 @@ describe('Referencing', () => { it('Label Empty', () => toXmlMatch( tex2mml('a\\label{}'), - ` - + ` + - - (1) + + (1) - a + a @@ -9155,22 +9089,22 @@ describe('Referencing', () => { it('Label Multiple', () => toXmlMatch( tex2mml('\\begin{eqnarray}a\\label{A}\\\\c\\label{B}\\end{eqnarray}'), - ` - + ` + - - (1) + + (1) - a + a - - (2) + + (2) - c + c @@ -9179,8 +9113,8 @@ describe('Referencing', () => { it('Label Multiple Error', () => toXmlMatch( tex2mml('a\\label{A}c\\label{B}'), - ` - + ` + Multiple \\label ` @@ -9188,8 +9122,8 @@ describe('Referencing', () => { it('Label Multiply Defined Error', () => toXmlMatch( tex2mml('\\begin{eqnarray}a\\label{A}\\\\c\\label{A}\\end{eqnarray}'), - ` - + ` + Label 'A' multiply defined ` @@ -9197,15 +9131,15 @@ describe('Referencing', () => { it('Ref', () => toXmlMatch( tex2mml('a\\label{A}\\ref{A}'), - ` - + ` + - - (1) + + (1) - a - + a + ??? @@ -9216,15 +9150,15 @@ describe('Referencing', () => { it('Ref Unknown', () => toXmlMatch( tex2mml('a\\label{A}\\ref{B}'), - ` - + ` + - - (1) + + (1) - a - + a + ??? @@ -9235,19 +9169,19 @@ describe('Referencing', () => { it('Nonumber', () => toXmlMatch( tex2mml('\\begin{eqnarray}a\\\\c\\nonumber\\end{eqnarray}'), - ` - + ` + - - (1) + + (1) - a + a - c + c @@ -9259,28 +9193,28 @@ describe('Complete Array', () => { it('column r c l', () => toXmlMatch( tex2mml('\\begin{array}{rcl}a & b &c\\\\ d & e & f\\end{array}'), - ` - - + ` + + - a + a - b + b - c + c - + - d + d - e + e - f + f @@ -9289,28 +9223,28 @@ describe('Complete Array', () => { it('column r c l | ', () => toXmlMatch( tex2mml('\\begin{array}{r|c|l}a & b & c\\\\d & e & f\\end{array}'), - ` - - + ` + + - a + a - b + b - c + c - + - d + d - e + e - f + f @@ -9319,28 +9253,28 @@ describe('Complete Array', () => { it('column r c l : ', () => toXmlMatch( tex2mml('\\begin{array}{r:c:l}a & b &c\\\\ d & e & f\\end{array}'), - ` - - + ` + + - a + a - b + b - c + c - + - d + d - e + e - f + f @@ -9349,40 +9283,40 @@ describe('Complete Array', () => { it('column r c l @ ', () => toXmlMatch( tex2mml('\\begin{array}{r@{h}c@{h}l}a & b &c\\\\ d & e & f\\end{array}'), - ` - + ` + - a + a - h + h - b + b - h + h - c + c - d + d - h + h - e + e - h + h - f + f @@ -9391,40 +9325,40 @@ describe('Complete Array', () => { it('column r c l ! ', () => toXmlMatch( tex2mml('\\begin{array}{r!{h}c!{h}l}a & b &c\\\\ d & e & f\\end{array}'), - ` - + ` + - a + a - h + h - b + b - h + h - c + c - d + d - h + h - e + e - h + h - f + f @@ -9433,39 +9367,39 @@ describe('Complete Array', () => { it('column p ', () => toXmlMatch( tex2mml('\\begin{array}{p{1cm}p{1cm}p{1cm}}a & b &c\\\\ d & e & f\\end{array}'), - ` - + ` + - - a + + a - - b + + b - - c + + c - - d + + d - - e + + e - - f + + f @@ -9475,39 +9409,39 @@ describe('Complete Array', () => { it('column m ', () => toXmlMatch( tex2mml('\\begin{array}{m{1cm}m{1cm}m{1cm}}a & b &c\\\\ d & e & f\\end{array}'), - ` - + ` + - - a + + a - - b + + b - - c + + c - - d + + d - - e + + e - - f + + f @@ -9517,39 +9451,39 @@ describe('Complete Array', () => { it('column b ', () => toXmlMatch( tex2mml('\\begin{array}{b{1cm}b{1cm}b{1cm}}a & b &c\\\\ d & e & f\\end{array}'), - ` - + ` + - - a + + a - - b + + b - - c + + c - - d + + d - - e + + e - - f + + f @@ -9559,30 +9493,30 @@ describe('Complete Array', () => { it('column r c l >', () => toXmlMatch( tex2mml('\\begin{array}{>{A}rcl}a & b &c\\\\ d & e & f\\end{array}'), - ` - + ` + - A - a + A + a - b + b - c + c - A - d + A + d - e + e - f + f @@ -9591,30 +9525,30 @@ describe('Complete Array', () => { it('column r c l <', () => toXmlMatch( tex2mml('\\begin{array}{r<{A}cl}a & b &c\\\\ d & e & f\\end{array}'), - ` - + ` + - a - A + a + A - b + b - c + c - d - A + d + A - e + e - f + f @@ -9623,18 +9557,18 @@ describe('Complete Array', () => { it('column c >', () => toXmlMatch( tex2mml('\\begin{array}{>{A}c}a \\\\ d\\end{array}'), - ` - + ` + - A - a + A + a - A - d + A + d @@ -9643,18 +9577,18 @@ describe('Complete Array', () => { it('column c <', () => toXmlMatch( tex2mml('\\begin{array}{c<{A}}a\\\\ d \\end{array}'), - ` - + ` + - a - A + a + A - d - A + d + A @@ -9663,22 +9597,22 @@ describe('Complete Array', () => { it('column c @ end', () => toXmlMatch( tex2mml('\\begin{array}{c@{h}}a\\\\ d \\end{array}'), - ` - + ` + - a + a - h + h - d + d - h + h @@ -9687,30 +9621,30 @@ describe('Complete Array', () => { it('column c @&', () => toXmlMatch( tex2mml('\\begin{array}{c@{\\alpha}c}a&\\hfill&b\\\\ d&\\hfill&e \\end{array}'), - ` - + ` + - a + a - - α + + α - b + b - d + d - - α + + α - e + e @@ -9719,32 +9653,32 @@ describe('Complete Array', () => { it('column c w', () => toXmlMatch( tex2mml('\\begin{array}{cw{c}{1cm}c}a&b&c\\\\ d&e&f \\end{array}'), - ` - - + ` + + - a + a - - b + + b - c + c - + - d + d - - e + + e - f + f @@ -9753,32 +9687,32 @@ describe('Complete Array', () => { it('column c W', () => toXmlMatch( tex2mml('\\begin{array}{cW{c}{1cm}c}a&b&c\\\\ d&e&f \\end{array}'), - ` - - + ` + + - a + a - - b + + b - c + c - + - d + d - - e + + e - f + f @@ -9787,28 +9721,28 @@ describe('Complete Array', () => { it('column repeat r c ', () => toXmlMatch( tex2mml('\\begin{array}{*{2}rc}a & b & c\\\\d & e & f\\end{array}'), - ` - - + ` + + - a + a - b + b - c + c - + - d + d - e + e - f + f @@ -9817,28 +9751,28 @@ describe('Complete Array', () => { it('column r repeat c ', () => toXmlMatch( tex2mml('\\begin{array}{r*{2}c}a & b & c\\\\d & e & f\\end{array}'), - ` - - + ` + + - a + a - b + b - c + c - + - d + d - e + e - f + f @@ -9847,42 +9781,38 @@ describe('Complete Array', () => { it('column r c repeat | ', () => toXmlMatch( tex2mml('\\begin{array}{r*{2}|c}a& b & c\\\\d & e & f\\end{array}'), - ` - + ` + - a - + a + - - - + - - b + + b - c + c - d - + d + - - - + - - e + + e - f + f @@ -9892,47 +9822,41 @@ describe('Complete Array', () => { it('column r c repeat | {}', () => toXmlMatch( tex2mml('\\begin{array}{r*{2}|c}a {\\hbox{(3)}}& b & c\\\\d & e & f\\end{array}'), - ` - + ` + - a - - - (3) - + a + + (3) - + - - - + - - b + + b - c + c - d - + d + - - - + - - e + + e - f + f @@ -9941,51 +9865,47 @@ describe('Complete Array', () => { it('column r c repeat | {}', () => toXmlMatch( tex2mml('\\begin{array}{r*{2}|c}a {\\begin{array}{c}Q\\end{array}}& b & c\\\\d & e & f\\end{array}'), - ` - + ` + - a - - - + a + + + - Q + Q - + - - - + - - b + + b - c + c - d - + d + - - - + - - e + + e - f + f @@ -9994,49 +9914,45 @@ describe('Complete Array', () => { it('column r c repeat | {}', () => toXmlMatch( tex2mml('\\begin{array}{r*{2}|c}a \\begin{array}{c}Q\\end{array}& b & c\\\\d & e & f\\end{array}'), - ` - + ` + - a - - + a + + - Q + Q - + - - - + - - b + + b - c + c - d - + d + - - - + - - e + + e - f + f @@ -10046,30 +9962,30 @@ describe('Complete Array', () => { it('column c @& hfil', () => toXmlMatch( tex2mml('\\begin{array}{c@{\\alpha}c}a&&b\\\\ d&&e\\hfil \\end{array}'), - ` - + ` + - a + a - α + α - b + b - d + d - α + α - - e + + e @@ -10078,8 +9994,8 @@ describe('Complete Array', () => { it('Label Error', () => toXmlMatch( tex2mml('\\eqalignno{a & & {\\hbox{(3)}}'), - ` - + ` + Missing close brace ` @@ -10088,28 +10004,28 @@ describe('Complete Array', () => { it('end row spacing r c l', () => toXmlMatch( tex2mml('\\begin{array}{rcl}a & b &c\\\\[2cm] d & e & f\\\\[2cm] \\end{array}'), - ` - - + ` + + - a + a - b + b - c + c - + - d + d - e + e - f + f @@ -10118,35 +10034,35 @@ describe('Complete Array', () => { it('eqnarray extend last row', () => toXmlMatch( tex2mml('\\begin{eqnarray}{rcl}a & b \\\\d&c&c&c \\\\\\end{eqnarray}'), - ` - + ` + - - r - c - l + + r + c + l - a + a - b + b - d + d - c + c - - c + + c - c + c @@ -10155,16 +10071,16 @@ describe('Complete Array', () => { it('end row hline c', () => toXmlMatch( tex2mml('\\begin{array}{|c|}\\hline a\\\\\\hline b\\\\\\hline\\end{array}'), - ` - - + ` + + - a + a - + - b + b @@ -10220,18 +10136,18 @@ describe('User Defined Macros', () => { it('Macro with optional def', () => toXmlMatch( tex2mml('\\RR'), - ` - - R + ` + + R ` )); it('EqRef', () => toXmlMatch( tex2mml('a\\label{A}\\eqref{A}'), - ` - a - + ` + a + (???) ` @@ -10239,32 +10155,32 @@ describe('User Defined Macros', () => { it('Right Color', () => toXmlMatch( tex2mml('\\left(A\\middle|B\\color{red}\\right)'), - ` - - ( - A - - | - - B - - ) + ` + + ( + A + + | + + B + + ) ` )); it('Middle Color', () => toXmlMatch( tex2mml('\\left(A\\color{red}\\middle|B\\right)'), - ` - - ( - A - - - | - - B - ) + ` + + ( + A + + + | + + B + ) ` )); @@ -10307,87 +10223,91 @@ describe('User Defined Environments', () => { it('smallmatrix', () => toXmlMatch( tex2mml('\\begin{smallmatrix} a & b \\\\ c & d \\end{smallmatrix}'), - ` - - - - a - - - b - - - - - c - - - d - - - + ` + + + + + a + + + b + + + + + c + + + d + + + + ` )); it('pmatrix', () => toXmlMatch( tex2mml('\\begin{pmatrix} a & b \\\\ c & d \\end{pmatrix}'), - ` - - ( - + ` + + ( + - a + a - b + b - c + c - d + d - ) + ) ` )); it('Crampedsubarray', () => toXmlMatch( tex2mml('\\begin{crampedsubarray}{cc} a & b \\\\ c & d \\end{crampedsubarray}'), - ` - - - - a - - - b - - - - - c - - - d - - - + ` + + + + + a + + + b + + + + + c + + + d + + + + ` )); it('Gather', () => toXmlMatch( tex2mml('\\begin{gather}a\\end{gather}'), - ` - + ` + - a + a From e78fc64a0b19d03c6dbe062a4617e280dc8cafd1 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 14 Nov 2024 17:12:12 -0500 Subject: [PATCH 05/10] Update ConfigMacros tests --- testsuite/tests/input/tex/Boldsymbol.test.ts | 2 +- .../tests/input/tex/ConfigMacros.test.ts | 54 +++++++++---------- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/testsuite/tests/input/tex/Boldsymbol.test.ts b/testsuite/tests/input/tex/Boldsymbol.test.ts index b6daa8c59..22a8b3626 100644 --- a/testsuite/tests/input/tex/Boldsymbol.test.ts +++ b/testsuite/tests/input/tex/Boldsymbol.test.ts @@ -47,7 +47,7 @@ describe('Boldsymbol', () => { a + b - +  w  c diff --git a/testsuite/tests/input/tex/ConfigMacros.test.ts b/testsuite/tests/input/tex/ConfigMacros.test.ts index ea68db5e4..01cc8769f 100644 --- a/testsuite/tests/input/tex/ConfigMacros.test.ts +++ b/testsuite/tests/input/tex/ConfigMacros.test.ts @@ -18,10 +18,10 @@ describe('Config Macros Active', () => { it('Macros Simple', () => runMacroTests( {active: {"@": "~"}}, - ` - A -   - a + ` + A +   + a `, 'A~a', 'A@a' @@ -32,9 +32,9 @@ describe('Config Macros Commands', () => { it('Commands Simple', () => runMacroTests( {macros: {"RR": "{\\bf R}"}}, - ` - - R + ` + + R `, '{\\bf R}', @@ -42,12 +42,12 @@ describe('Config Macros Commands', () => { it('Commands Argument', () => runMacroTests( {macros: {"bold": ["{\\bf #1}", 1]}}, - ` - - b - o - l - d + ` + + b + o + l + d `, '{\\bf bold}', @@ -55,20 +55,20 @@ describe('Config Macros Commands', () => { it('Commands Aux Argument', () => runMacroTests( {macros: {"foo": ["\\mbox{first } #1 \\mbox{ second } #2", 2, ["[", "]"]]}}, - ` - + ` + first  - h - i - + h + i +  second  - t - h - e - r - e + t + h + e + r + e `, '\\mbox{first } hi \\mbox{ second } there', '\\foo[hi]{there}')); @@ -78,10 +78,10 @@ describe('Config Macros Environment', () => { it('Environment Simple', () => runMacroTests( {environments: {"myHeartEnv": ["\\heartsuit", "\\spadesuit"]}}, - ` - - a - + ` + + a + `, '\\begin{myHeartEnv}a\\end{myHeartEnv}', '\\begin{myHeartEnv}a\\end{myHeartEnv}' From ecc4bedd31ff01e5b8bd5b1657e3683ca70d3cc1 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 14 Nov 2024 17:56:55 -0500 Subject: [PATCH 06/10] Update Unicode tests --- testsuite/tests/input/tex/Extpfeil.test.ts | 44 ++++++++-------------- testsuite/tests/input/tex/Unicode.test.ts | 2 +- 2 files changed, 17 insertions(+), 29 deletions(-) diff --git a/testsuite/tests/input/tex/Extpfeil.test.ts b/testsuite/tests/input/tex/Extpfeil.test.ts index 4080f474a..83da14f23 100644 --- a/testsuite/tests/input/tex/Extpfeil.test.ts +++ b/testsuite/tests/input/tex/Extpfeil.test.ts @@ -10,9 +10,7 @@ describe('Extpfeil', () => { tex2mml('\\xtwoheadrightarrow{abcxyz}'), ` - - - + a b @@ -30,9 +28,7 @@ describe('Extpfeil', () => { tex2mml('\\xtwoheadleftarrow{abcxyz}'), ` - - - + a b @@ -50,9 +46,7 @@ describe('Extpfeil', () => { tex2mml('\\xmapsto{abcxyz}'), ` - - - + a b @@ -70,9 +64,7 @@ describe('Extpfeil', () => { tex2mml('\\xlongequal{abcxyz}'), ` - - = - + = a b @@ -90,9 +82,7 @@ describe('Extpfeil', () => { tex2mml('\\xtofrom{abcxyz}'), ` - - - + a b @@ -110,9 +100,7 @@ describe('Extpfeil', () => { tex2mml('\\Newextarrow{\\ab}{10,20}{8672}\\ab{xyz}'), ` - - - + x y @@ -128,8 +116,8 @@ describe('Extpfeil Errors', () => { it('NewextarrowArg1', () => toXmlMatch( tex2mml('\\Newextarrow{ab}{10,20}{8672}\\ab{xyz}'), - ` - + ` + First argument to \\Newextarrow must be a control sequence name ` @@ -137,8 +125,8 @@ describe('Extpfeil Errors', () => { it('NewextarrowArg2 One', () => toXmlMatch( tex2mml('\\Newextarrow{\\ab}{10}{8672}\\ab{xyz}'), - ` - + ` + Second argument to \\Newextarrow must be two integers separated by a comma ` @@ -146,8 +134,8 @@ describe('Extpfeil Errors', () => { it('NewextarrowArg2 Two', () => toXmlMatch( tex2mml('\\Newextarrow{\\ab}{10 20}{8672}\\ab{xyz}'), - ` - + ` + Second argument to \\Newextarrow must be two integers separated by a comma ` @@ -155,8 +143,8 @@ describe('Extpfeil Errors', () => { it('NewextarrowArg2 Three', () => toXmlMatch( tex2mml('\\Newextarrow{\\ab}{aa}{8672}\\ab{xyz}'), - ` - + ` + Second argument to \\Newextarrow must be two integers separated by a comma ` @@ -164,8 +152,8 @@ describe('Extpfeil Errors', () => { it('NewextarrowArg3', () => toXmlMatch( tex2mml('\\Newextarrow{\\ab}{10,20}{AG}\\ab{xyz}'), - ` - + ` + Third argument to \\Newextarrow must be a unicode character number ` diff --git a/testsuite/tests/input/tex/Unicode.test.ts b/testsuite/tests/input/tex/Unicode.test.ts index 398ca341e..cc7d5123b 100644 --- a/testsuite/tests/input/tex/Unicode.test.ts +++ b/testsuite/tests/input/tex/Unicode.test.ts @@ -53,7 +53,7 @@ describe('Unicode', () => { toXmlMatch( tex2mml('\\mbox{A}\\unicode{65}{B}'), ` - + A A From 216edbe93c023dd4e840bea639fe413f61b237e9 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 14 Nov 2024 20:44:00 -0500 Subject: [PATCH 07/10] Update Bussproofs tests --- testsuite/tests/input/tex/Bussproofs.test.ts | 1882 +++++++----------- 1 file changed, 763 insertions(+), 1119 deletions(-) diff --git a/testsuite/tests/input/tex/Bussproofs.test.ts b/testsuite/tests/input/tex/Bussproofs.test.ts index c4ef5a2b3..2b29bd9e5 100644 --- a/testsuite/tests/input/tex/Bussproofs.test.ts +++ b/testsuite/tests/input/tex/Bussproofs.test.ts @@ -12,7 +12,7 @@ describe('BussproofsRegInf', () => { ` - + A @@ -31,9 +31,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -45,9 +43,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -69,9 +65,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -79,9 +73,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -93,9 +85,7 @@ describe('BussproofsRegInf', () => { - - C - + C @@ -117,9 +107,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -127,9 +115,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -137,9 +123,7 @@ describe('BussproofsRegInf', () => { - - C - + C @@ -151,9 +135,7 @@ describe('BussproofsRegInf', () => { - - D - + D @@ -175,9 +157,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -185,9 +165,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -195,9 +173,7 @@ describe('BussproofsRegInf', () => { - - C - + C @@ -205,9 +181,7 @@ describe('BussproofsRegInf', () => { - - D - + D @@ -219,9 +193,7 @@ describe('BussproofsRegInf', () => { - - E - + E @@ -243,9 +215,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -253,9 +223,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -263,9 +231,7 @@ describe('BussproofsRegInf', () => { - - C - + C @@ -273,9 +239,7 @@ describe('BussproofsRegInf', () => { - - D - + D @@ -283,9 +247,7 @@ describe('BussproofsRegInf', () => { - - E - + E @@ -297,9 +259,7 @@ describe('BussproofsRegInf', () => { - - F - + F @@ -315,7 +275,7 @@ describe('BussproofsRegInf', () => { ` - + L @@ -327,9 +287,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -341,9 +299,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -367,9 +323,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -381,16 +335,14 @@ describe('BussproofsRegInf', () => { - - B - + B - + R @@ -405,7 +357,7 @@ describe('BussproofsRegInf', () => { ` - + L @@ -417,9 +369,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -431,16 +381,14 @@ describe('BussproofsRegInf', () => { - - B - + B - + R @@ -453,7 +401,7 @@ describe('BussproofsRegInf', () => { ` - + A @@ -472,9 +420,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -486,9 +432,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -508,9 +452,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -518,9 +460,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -532,9 +472,7 @@ describe('BussproofsRegInf', () => { - - C - + C @@ -556,9 +494,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -566,9 +502,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -576,9 +510,7 @@ describe('BussproofsRegInf', () => { - - C - + C @@ -590,9 +522,7 @@ describe('BussproofsRegInf', () => { - - D - + D @@ -608,7 +538,7 @@ describe('BussproofsRegInf', () => { ` - + L @@ -620,9 +550,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -634,9 +562,7 @@ describe('BussproofsRegInf', () => { - - B - + B @@ -660,9 +586,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -674,16 +598,14 @@ describe('BussproofsRegInf', () => { - - B - + B - + R @@ -698,7 +620,7 @@ describe('BussproofsRegInf', () => { ` - + L @@ -710,9 +632,7 @@ describe('BussproofsRegInf', () => { - - A - + A @@ -724,16 +644,14 @@ describe('BussproofsRegInf', () => { - - B - + B - + R @@ -758,9 +676,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -775,9 +691,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -791,9 +705,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -801,9 +713,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -815,15 +725,13 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + @@ -838,9 +746,7 @@ describe('BussproofsRegProofs', () => { - - E - + E @@ -857,9 +763,7 @@ describe('BussproofsRegProofs', () => { - - F - + F @@ -891,9 +795,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -908,9 +810,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -924,9 +824,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -934,9 +832,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -948,15 +844,13 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + @@ -971,9 +865,7 @@ describe('BussproofsRegProofs', () => { - - E - + E @@ -990,9 +882,7 @@ describe('BussproofsRegProofs', () => { - - F - + F @@ -1034,9 +924,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -1044,9 +932,7 @@ describe('BussproofsRegProofs', () => { - - A1 - + A1 @@ -1054,9 +940,7 @@ describe('BussproofsRegProofs', () => { - - A2 - + A2 @@ -1068,9 +952,7 @@ describe('BussproofsRegProofs', () => { - - Q - + Q @@ -1089,9 +971,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -1105,9 +985,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -1115,9 +993,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -1129,15 +1005,13 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + @@ -1152,9 +1026,7 @@ describe('BussproofsRegProofs', () => { - - E - + E @@ -1171,9 +1043,7 @@ describe('BussproofsRegProofs', () => { - - F - + F @@ -1187,9 +1057,7 @@ describe('BussproofsRegProofs', () => { - - M - + M @@ -1201,13 +1069,11 @@ describe('BussproofsRegProofs', () => { - - - N - - R - - + + N + + R + @@ -1252,9 +1118,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -1262,9 +1126,7 @@ describe('BussproofsRegProofs', () => { - - A1 - + A1 @@ -1272,9 +1134,7 @@ describe('BussproofsRegProofs', () => { - - A2 - + A2 @@ -1286,9 +1146,7 @@ describe('BussproofsRegProofs', () => { - - Q - + Q @@ -1308,9 +1166,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -1326,9 +1182,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -1336,9 +1190,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -1350,24 +1202,20 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + - - AAAA - + AAAA @@ -1381,18 +1229,14 @@ describe('BussproofsRegProofs', () => { - - E - + E - - BBB - + BBB @@ -1406,18 +1250,14 @@ describe('BussproofsRegProofs', () => { - - F - + F - - CCCCC - + CCCCC @@ -1429,9 +1269,7 @@ describe('BussproofsRegProofs', () => { - - M - + M @@ -1443,20 +1281,18 @@ describe('BussproofsRegProofs', () => { - - - N - - R - - + + N + + R + - + QERE @@ -1474,7 +1310,7 @@ describe('BussproofsRegProofs', () => { - + QERE @@ -1491,9 +1327,7 @@ describe('BussproofsRegProofs', () => { - - CCCCC - + CCCCC @@ -1511,9 +1345,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -1521,9 +1353,7 @@ describe('BussproofsRegProofs', () => { - - A1 - + A1 @@ -1531,9 +1361,7 @@ describe('BussproofsRegProofs', () => { - - A2 - + A2 @@ -1545,9 +1373,7 @@ describe('BussproofsRegProofs', () => { - - Q - + Q @@ -1560,9 +1386,7 @@ describe('BussproofsRegProofs', () => { - - BBB - + BBB @@ -1572,9 +1396,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -1582,9 +1404,7 @@ describe('BussproofsRegProofs', () => { - - AAAA - + AAAA @@ -1594,9 +1414,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -1604,9 +1422,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -1618,15 +1434,13 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + @@ -1642,9 +1456,7 @@ describe('BussproofsRegProofs', () => { - - E - + E @@ -1662,9 +1474,7 @@ describe('BussproofsRegProofs', () => { - - F - + F @@ -1680,9 +1490,7 @@ describe('BussproofsRegProofs', () => { - - M - + M @@ -1694,13 +1502,11 @@ describe('BussproofsRegProofs', () => { - - - N - - R - - + + N + + R + @@ -1720,7 +1526,7 @@ describe('BussproofsRegProofs', () => { - + DD @@ -1737,9 +1543,7 @@ describe('BussproofsRegProofs', () => { - - CCCCC - + CCCCC @@ -1757,9 +1561,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -1767,9 +1569,7 @@ describe('BussproofsRegProofs', () => { - - A1 - + A1 @@ -1777,9 +1577,7 @@ describe('BussproofsRegProofs', () => { - - A2 - + A2 @@ -1791,9 +1589,7 @@ describe('BussproofsRegProofs', () => { - - Q - + Q @@ -1806,9 +1602,7 @@ describe('BussproofsRegProofs', () => { - - BBB - + BBB @@ -1818,9 +1612,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -1836,9 +1628,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -1846,9 +1636,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -1860,24 +1648,20 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + - - AAAA - + AAAA @@ -1891,9 +1675,7 @@ describe('BussproofsRegProofs', () => { - - E - + E @@ -1911,9 +1693,7 @@ describe('BussproofsRegProofs', () => { - - F - + F @@ -1929,9 +1709,7 @@ describe('BussproofsRegProofs', () => { - - M - + M @@ -1943,20 +1721,18 @@ describe('BussproofsRegProofs', () => { - - - N - - R - - + + N + + R + - + QERE @@ -2000,9 +1776,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -2010,9 +1784,7 @@ describe('BussproofsRegProofs', () => { - - A1 - + A1 @@ -2020,9 +1792,7 @@ describe('BussproofsRegProofs', () => { - - A2 - + A2 @@ -2034,18 +1804,14 @@ describe('BussproofsRegProofs', () => { - - Q - + Q - - AAAA - + AAAA @@ -2062,9 +1828,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -2080,9 +1844,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -2090,9 +1852,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -2104,24 +1864,20 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + - - Nowhere - + Nowhere @@ -2135,18 +1891,14 @@ describe('BussproofsRegProofs', () => { - - E - + E - - BBB - + BBB @@ -2160,18 +1912,14 @@ describe('BussproofsRegProofs', () => { - - F - + F - - CCCCC - + CCCCC @@ -2203,9 +1951,7 @@ describe('BussproofsRegProofs', () => { - - M - + M @@ -2217,18 +1963,14 @@ describe('BussproofsRegProofs', () => { - - More and more - + More and more - - QERE - + QERE @@ -2242,9 +1984,7 @@ describe('BussproofsRegProofs', () => { - - More and more - + More and more @@ -2259,9 +1999,7 @@ describe('BussproofsRegProofs', () => { - - More and more - + More and more @@ -2276,13 +2014,11 @@ describe('BussproofsRegProofs', () => { - - - N - - R - - + + N + + R + @@ -2297,636 +2033,584 @@ describe('BussproofsRegProofs', () => { tex2mml( '\\begin{prooftree}\\AXC{}\\RL{$Hyp^{1}$}\\UIC{$P$}\\AXC{$P\\rightarrow Q$}\\RL{$\\rightarrow_E$}\\solidLine\\BIC{$Q^2$}\\AXC{$Q\\rightarrow R$} \\RL{$\\rightarrow_E$} \\BIC{$R$} \\AXC{$Q$}\\RL{Rit$^2$} \\UIC{$Q$}\\RL{$\\wedge_I$}\\BIC{$Q\\wedge R$}\\RL{${\\rightarrow_I}^1$}\\UIC{$P\\rightarrow Q\\wedge R$}\\end{prooftree}' ), - ` - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - P + ` + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + P + + - - + + + + + + H + y + + p + + 1 + + - - - - - + + + + + + + - H - y - - p - - 1 - - + P + + Q - - - - - - - - - - - P - - Q + - - + + + + + + + + + + + + Q + 2 + - - - - - - - - - - - - - Q - 2 - + - - + + + + + + + + E + - - - - - - - - - E - - - - - - - - - - - - - - Q - - R + + - - - - - - - - - - - - - - - R - - - - - - - - - - - - - E - - - - - - - - - - - - - - - - + + + + + + + Q + + R + + + + + + + + - - + + - - - Q - - + + R + - - - - - - - - - Q - - - - - - - - - - Rit - - - - 2 - + + + + + E + + + - - - - + + + + + + + + + + + + + + + + + Q + + + + + + + + + + + + + + Q + + + + + + + + + Rit + + + + 2 + + + + + + + + + + + + + + + + + + Q + + R - - - - - - - - - - - - Q - - R + - - + + + + + + + + I + - - - - - - - - - I - - - - + + + + - - + + + + + + + + + + + P + + Q + + R - - - - - - - - - - - - P - - Q - - R + - - - - - - - - - - - - - - I - + + + + + + + + + + + I + + + 1 + - 1 - - - - + + + + + - - - -` + ` )); it('Proof Mixing Order', () => toXmlMatch( tex2mml( - '\\begin{prooftree}\\alwaysRootAtTop\\AXC{}\\RL{$Hyp^{1}$}\\UIC{$P$}\\AXC{$P\\rightarrow Q$}\\RL{$\\rightarrow_E$}\\solidLine\\BIC{$Q^2$}\\alwaysRootAtBottom\\AXC{$Q\\rightarrow R$} \\RL{$\\rightarrow_E$} \\BIC{$R$} \\AXC{$Q$}\\RL{Rit$^2$} \\UIC{$Q$}\\RL{$\\wedge_I$}\\BIC{$Q\\wedge R$}\\RL{${\\rightarrow_I}^1$}\\UIC{$P\\rightarrow Q\\wedge R$}\\end{prooftree}' + '\\begin{prooftree}\\alwaysRootAtTop\\AXC{}\\RL{$Hyp^{1}$}\\UIC{$P$}\\AXC{$P\\rightarrow Q$}\\RL{$\\rightarrow_E$}\\solidLine\\BIC{$Q^2$}\\alwaysRootAtBottom\\AXC{$Q\\rightarrow R$} \\RL{$\\rightarrow_E$} \\BIC{$R$} \\AXC{$Q$}\\RL{Rit$^2$} \\UIC{$Q$}\\RL{$\\wedge_I$}\\BIC{$Q\\wedge R$}\\RL{\${\\rightarrow_I}^1$}\\UIC{$P\\rightarrow Q\\wedge R$}\\end{prooftree}' ), - ` - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Q - 2 - + ` + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Q + 2 + + + - - - - - - - - - - - - - - - - - - - P + + + + + + + + + + + + + + + P + + + + + + + + + + + + + + + + + + + + H + y + + p + + 1 - - + - - - - - - - - - - - - - - - - + + + + + + + - H - y - - p - - 1 - - + P + + Q - - - - - - - - - - - P - - Q + - - - - - - - - - - - - - - - E - - - - - - - - - - - - - - Q - - R + + + + + + + + + + + E + + + + - - - - - - - - - - - - - - - R - - - - - - - - - - - - - E - - - - - - - - - - - - - - - - + + + + + + + Q + + R + + + + + + + + - - + + - - - Q - - + + R + - - - - - - - - - Q - - - - - - - - - - Rit - - - - 2 - + + + + + E + + + - - - - + + + + + + + + + + + + + + + + + Q + + + + + + + + + + + + + + Q + + + + + + + + + Rit + + + + 2 + + + + + + + + + + + + + + + + + + Q + + R - - - - - - - - - - - - Q - - R + - - + + + + + + + + I + - - - - - - - - - I - - - - + + + + - - + + + + + + + + + + + P + + Q + + R - - - - - - - - - - - - P - - Q - - R + - - - - - - - - - - - - - - I - + + + + + + + + + + + I + + + 1 + - 1 - - - - + + + + + - - - -` + ` )); it('Extreme', () => toXmlMatch( @@ -2938,7 +2622,7 @@ describe('BussproofsRegProofs', () => { - + BBB @@ -2954,9 +2638,7 @@ describe('BussproofsRegProofs', () => { - - WWW - + WWW @@ -2968,9 +2650,7 @@ describe('BussproofsRegProofs', () => { - - HHHHH - + HHHHH @@ -2980,9 +2660,7 @@ describe('BussproofsRegProofs', () => { - - D - + D @@ -2990,9 +2668,7 @@ describe('BussproofsRegProofs', () => { - - A1 - + A1 @@ -3000,9 +2676,7 @@ describe('BussproofsRegProofs', () => { - - A2 - + A2 @@ -3014,18 +2688,14 @@ describe('BussproofsRegProofs', () => { - - Q - + Q - - 11111111111111111 - + 11111111111111111 @@ -3035,9 +2705,7 @@ describe('BussproofsRegProofs', () => { - - BBBB - + BBBB @@ -3047,9 +2715,7 @@ describe('BussproofsRegProofs', () => { - - A - + A @@ -3058,9 +2724,7 @@ describe('BussproofsRegProofs', () => { - - qqqq - + qqqq @@ -3070,9 +2734,7 @@ describe('BussproofsRegProofs', () => { - - B - + B @@ -3080,9 +2742,7 @@ describe('BussproofsRegProofs', () => { - - R - + R @@ -3094,24 +2754,20 @@ describe('BussproofsRegProofs', () => { - - - C - - D - - Q - - + + C + + D + + Q + - - AAAA - + AAAA @@ -3125,18 +2781,14 @@ describe('BussproofsRegProofs', () => { - - E - + E - - MMM - + MMM @@ -3150,18 +2802,14 @@ describe('BussproofsRegProofs', () => { - - F - + F - - CCCCC - + CCCCC @@ -3173,9 +2821,7 @@ describe('BussproofsRegProofs', () => { - - M - + M @@ -3187,20 +2833,18 @@ describe('BussproofsRegProofs', () => { - - - N - - R - - + + N + + R + - + QERE From 1a97e5d4161e48ef819fb5084edf60a73d4a0cb0 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Fri, 15 Nov 2024 10:39:39 -0500 Subject: [PATCH 08/10] Update Mhchem tests --- testsuite/tests/input/tex/Mhchem.test.ts | 200 +++++++---------------- 1 file changed, 55 insertions(+), 145 deletions(-) diff --git a/testsuite/tests/input/tex/Mhchem.test.ts b/testsuite/tests/input/tex/Mhchem.test.ts index 26383d6ac..6e0423fc1 100644 --- a/testsuite/tests/input/tex/Mhchem.test.ts +++ b/testsuite/tests/input/tex/Mhchem.test.ts @@ -44,9 +44,7 @@ describe('Mhchem0', () => { 2 - - - + CO @@ -99,7 +97,7 @@ describe('Mhchem0', () => { 75.3   - + J @@ -375,9 +373,7 @@ describe('Mhchem1', () => { ` 2 - - - + H @@ -411,9 +407,7 @@ describe('Mhchem1', () => { ` 2 - - - + H @@ -447,9 +441,7 @@ describe('Mhchem1', () => { ` 0.5 - - - + H @@ -482,15 +474,13 @@ describe('Mhchem1', () => { tex2mml('\\ce{1/2 H2O}'), ` - - + + 1 2 - - - + H @@ -530,9 +520,7 @@ describe('Mhchem1', () => { 2 ) - - - + H @@ -566,9 +554,7 @@ describe('Mhchem1', () => { ` n - - - + H @@ -1295,12 +1281,8 @@ describe('Mhchem2', () => { - - - - - - + + @@ -1308,16 +1290,12 @@ describe('Mhchem2', () => { - + - - - - - - + + @@ -1353,16 +1331,12 @@ describe('Mhchem2', () => { - + - - - - - - + + @@ -1396,12 +1370,8 @@ describe('Mhchem2', () => { - - - - - - + + @@ -1409,7 +1379,7 @@ describe('Mhchem2', () => { - + @@ -1605,9 +1575,7 @@ describe('Mhchem3', () => { + 2 - - - + ( @@ -1634,15 +1602,13 @@ describe('Mhchem3', () => { + - + 79 21 - - - + N @@ -3029,19 +2995,13 @@ describe('Mhchem6', () => { - - - + - - - + 12 - - - + H @@ -3118,19 +3078,13 @@ describe('Mhchem6', () => { - - - + - - - + 12 - - - + H @@ -3207,19 +3161,13 @@ describe('Mhchem6', () => { - - - + - - - + 12 - - - + H @@ -3968,12 +3916,8 @@ describe('Mhchem8', () => { - - - - - - + + @@ -3981,16 +3925,12 @@ describe('Mhchem8', () => { - + - - - - - - + + @@ -4101,12 +4041,8 @@ describe('Mhchem8', () => { - - - - - - + + @@ -4114,16 +4050,12 @@ describe('Mhchem8', () => { - + - - - - - - + + @@ -4502,7 +4434,7 @@ describe('Mhchem9', () => { 123   - + kJ @@ -4683,9 +4615,7 @@ describe('Mhchem-Ams', () => { - - - + I @@ -4733,9 +4663,7 @@ describe('Mhchem-Ams', () => { - - - + I @@ -4830,9 +4758,7 @@ describe('Mhchem-Ams', () => { - - - + H @@ -4880,9 +4806,7 @@ describe('Mhchem-Ams', () => { - - - + @@ -4917,9 +4841,7 @@ describe('Mhchem-Ams', () => { - - - + @@ -4948,9 +4870,7 @@ describe('Mhchem-Ams', () => { ` x - - - + Na @@ -5001,9 +4921,7 @@ describe('Mhchem-Ams', () => { - - - + Δ @@ -5058,9 +4976,7 @@ describe('Mhchem-Ams', () => { + x - - - + NH @@ -5088,9 +5004,7 @@ describe('Mhchem-Ams', () => { + x - - - + H @@ -5146,9 +5060,7 @@ describe('Mhchem-Ams', () => { - - - + I @@ -5203,9 +5115,7 @@ describe('Mhchem-Ams', () => { - - - + I From 6c5b48c25523af1196dac6c46e8b2b72cde387a9 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Fri, 15 Nov 2024 10:39:45 -0500 Subject: [PATCH 09/10] Update Tag tests --- testsuite/tests/input/tex/Tag.test.ts | 144 +++++++++++++------------- 1 file changed, 72 insertions(+), 72 deletions(-) diff --git a/testsuite/tests/input/tex/Tag.test.ts b/testsuite/tests/input/tex/Tag.test.ts index fd9ff6b9c..e85c0db51 100644 --- a/testsuite/tests/input/tex/Tag.test.ts +++ b/testsuite/tests/input/tex/Tag.test.ts @@ -8,7 +8,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('a'), ` - + (1) @@ -24,7 +24,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\end{align}'), ` - + (1) @@ -40,7 +40,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{multline}a\\\\ b\\\\ c\\end{multline}'), ` - + a @@ -66,7 +66,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{}\\end{align}'), ` - + (1) @@ -82,7 +82,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}'), ` - + (1) @@ -98,7 +98,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\notag\\end{align}'), ` - + a @@ -111,7 +111,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{multline}a\\\\ b\\\\ c\\notag\\end{multline}'), ` - + a @@ -134,7 +134,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\notag\\end{align}'), ` - + a @@ -147,7 +147,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{A}'), ` - + (1) @@ -166,7 +166,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{B}'), ` - + (1) @@ -185,7 +185,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\eqref{A}'), ` - + (1) @@ -204,7 +204,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a=b\\label{A}\\\\ c&=d \\label{B}\\end{align}'), ` - + (1) @@ -273,7 +273,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\end{align}'), ` - + (1) @@ -289,7 +289,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\end{align}'), ` - + (A) @@ -305,7 +305,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\\\b\\end{align}'), ` - + (A) @@ -329,7 +329,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\\\b\\tag{B}\\end{align}'), ` - + (A) @@ -353,7 +353,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}'), ` - + (1) @@ -369,7 +369,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\end{align}'), ` - + (A) @@ -385,7 +385,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\\\b\\label{B}\\end{align}'), ` - + (A) @@ -411,7 +411,7 @@ describe('TagAll', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\tag{B}\\label{B}\\end{align}' ), ` - + (A) @@ -435,7 +435,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{A}'), ` - + (1) @@ -454,7 +454,7 @@ describe('TagAll', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\end{align}\\ref{A}'), ` - + (A) @@ -475,7 +475,7 @@ describe('TagAll', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\label{B}\\end{align}\\ref{A}\\ref{B}' ), ` - + (A) @@ -507,7 +507,7 @@ describe('TagAll', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\tag{B}\\label{B}\\end{align}\\ref{A}\\ref{B}' ), ` - + (A) @@ -548,7 +548,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('a\\tag{0}'), ` - + (0) @@ -564,7 +564,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\end{align}'), ` - + a @@ -577,7 +577,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{split}a\\end{split}'), ` - + a @@ -590,7 +590,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{multline}a\\\\ b\\\\ c\\end{multline}'), ` - + a @@ -613,7 +613,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{}\\end{align}'), ` - + a @@ -626,7 +626,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}'), ` - + a @@ -639,7 +639,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\notag\\end{align}'), ` - + a @@ -652,7 +652,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{multline}a\\\\ b\\\\ c\\notag\\end{multline}'), ` - + a @@ -675,7 +675,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\notag\\end{align}'), ` - + a @@ -688,7 +688,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{A}'), ` - + a @@ -704,7 +704,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{B}'), ` - + a @@ -720,7 +720,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\eqref{A}'), ` - + a @@ -781,7 +781,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\end{align}'), ` - + a @@ -794,7 +794,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\end{align}'), ` - + (A) @@ -810,7 +810,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\\\b\\end{align}'), ` - + (A) @@ -831,7 +831,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\\\b\\tag{B}\\end{align}'), ` - + (A) @@ -855,7 +855,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}'), ` - + a @@ -868,7 +868,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\end{align}'), ` - + (A) @@ -884,7 +884,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\\\b\\label{B}\\end{align}'), ` - + (A) @@ -907,7 +907,7 @@ describe('TagNone', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\tag{B}\\label{B}\\end{align}' ), ` - + (A) @@ -931,7 +931,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{A}'), ` - + a @@ -947,7 +947,7 @@ describe('TagNone', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\end{align}\\ref{A}'), ` - + (A) @@ -968,7 +968,7 @@ describe('TagNone', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\label{B}\\end{align}\\ref{A}\\ref{B}' ), ` - + (A) @@ -997,7 +997,7 @@ describe('TagNone', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\tag{B}\\label{B}\\end{align}\\ref{A}\\ref{B}' ), ` - + (A) @@ -1038,7 +1038,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\end{align}'), ` - + (1) @@ -1054,7 +1054,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{split}a\\end{split}'), ` - + a @@ -1067,7 +1067,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{multline}a\\\\ b\\\\ c\\end{multline}'), ` - + a @@ -1093,7 +1093,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{}\\end{align}'), ` - + (1) @@ -1109,7 +1109,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}'), ` - + (1) @@ -1125,7 +1125,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\notag\\end{align}'), ` - + a @@ -1138,7 +1138,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{multline}a\\\\ b\\\\ c\\notag\\end{multline}'), ` - + a @@ -1161,7 +1161,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\notag\\end{align}'), ` - + a @@ -1174,7 +1174,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{A}'), ` - + (1) @@ -1193,7 +1193,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{B}'), ` - + (1) @@ -1212,7 +1212,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\eqref{A}'), ` - + (1) @@ -1231,7 +1231,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a=b\\label{A}\\\\ c&=d \\label{B}\\end{align}'), ` - + (1) @@ -1300,7 +1300,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\end{align}'), ` - + (1) @@ -1316,7 +1316,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\end{align}'), ` - + (A) @@ -1332,7 +1332,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\\\b\\end{align}'), ` - + (A) @@ -1356,7 +1356,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\\\b\\tag{B}\\end{align}'), ` - + (A) @@ -1380,7 +1380,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}'), ` - + (1) @@ -1396,7 +1396,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\end{align}'), ` - + (A) @@ -1412,7 +1412,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\\\b\\label{B}\\end{align}'), ` - + (A) @@ -1438,7 +1438,7 @@ describe('TagAms', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\tag{B}\\label{B}\\end{align}' ), ` - + (A) @@ -1462,7 +1462,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\label{A}\\end{align}\\ref{A}'), ` - + (1) @@ -1481,7 +1481,7 @@ describe('TagAms', () => { toXmlMatch( tex2mml('\\begin{align}a\\tag{A}\\label{A}\\end{align}\\ref{A}'), ` - + (A) @@ -1502,7 +1502,7 @@ describe('TagAms', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\label{B}\\end{align}\\ref{A}\\ref{B}' ), ` - + (A) @@ -1534,7 +1534,7 @@ describe('TagAms', () => { '\\begin{align}a\\tag{A}\\label{A}\\\\b\\tag{B}\\label{B}\\end{align}\\ref{A}\\ref{B}' ), ` - + (A) From 9c801745a49bb331b6f496813145bc35bd873f1e Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Fri, 15 Nov 2024 10:48:08 -0500 Subject: [PATCH 10/10] Remove unneeded escaped quotes --- testsuite/tests/input/tex/Braket.test.ts | 28 ++++++++++----------- testsuite/tests/input/tex/Physics.test.ts | 30 +++++++++++------------ 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/testsuite/tests/input/tex/Braket.test.ts b/testsuite/tests/input/tex/Braket.test.ts index ffa59ca24..9e3154d61 100644 --- a/testsuite/tests/input/tex/Braket.test.ts +++ b/testsuite/tests/input/tex/Braket.test.ts @@ -205,11 +205,11 @@ describe('Braket', () => { it('Braket-Set-small', () => toXmlMatch( tex2mml('\\set{x}'), - ` - - { - x - } + ` + + { + x + } ` )); @@ -265,16 +265,16 @@ describe('Braket', () => { it('Braket-Set-over', () => toXmlMatch( tex2mml('\\Set{x\\over y}'), - ` - - { - - - x - y + ` + + { + + + x + y - - } + + } ` )); diff --git a/testsuite/tests/input/tex/Physics.test.ts b/testsuite/tests/input/tex/Physics.test.ts index 613dcab42..0efcd477e 100644 --- a/testsuite/tests/input/tex/Physics.test.ts +++ b/testsuite/tests/input/tex/Physics.test.ts @@ -8602,23 +8602,23 @@ describe('Physics7_11', () => { it('Matrices_Other_8', () => toXmlMatch( tex2mml('\\begin{smallmatrix} a & b \\\\ c & d \\end{smallmatrix}'), - ` - - + ` + + - a + a - b + b - c + c - d + d @@ -9246,24 +9246,24 @@ describe('Physics7_2', () => { it('Matrices_Small_1', () => toXmlMatch( tex2mml('\\smallmatrixquantity*{a & b \\\\ c & d}'), - ` - - + ` + + - - a + + a - b + b - c + c - d + d