test: expose MathmlTag name and add no superscript mscript use case

This commit is contained in:
Alexandre Nunes 2020-09-20 16:14:09 -03:00
parent 75c386780c
commit 79e625ad78
2 changed files with 23 additions and 0 deletions

@ -895,5 +895,15 @@ describe('#convert', () => {
expect(result).toBe('\\left(N a\\right)_{11}^{+}');
});
});
describe('with subscript only, without preset', () => {
it('handler it as it were a subsup tag', () => {
const mathml = mathmlStrings.mmultiscriptNoSuper;
const result = MathMLToLaTeX.convert(mathml);
expect(result).toBe('\\left(N a\\right)_{11}^{}');
});
});
});
});

@ -1486,3 +1486,16 @@ export const mmultiscript = `<math xmlns="http://www.w3.org/1998/Math/MathML" di
</mrow>
</mmultiscripts>
</math>`;
export const mmultiscriptNoSuper = `<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
<mmultiscripts>
<mrow>
<mi>N</mi>
<mi>a</mi>
</mrow>
<mrow>
<mn>11</mn>
</mrow>
<none/>
</mmultiscripts>
</math>`;