test: bar divider translated to single bar

This commit is contained in:
Alexandre Nunes 2021-01-07 11:22:25 -03:00
parent de3faab84e
commit c4a7df61fb
2 changed files with 20 additions and 0 deletions

@ -64,6 +64,14 @@ describe('#convert', () => {
expect(result).toMatch('+');
});
it('converts bar divider preserving it', () => {
const mathml = mathmlStrings.moDividerOperator;
const result = MathMLToLaTeX.convert(mathml);
expect(result).toMatch('x=4/5');
});
});
describe('with Glyph operator', () => {

@ -64,6 +64,18 @@ export const moWithSimpleOperator = `
</root>
`;
export const moDividerOperator = `
<math>
<mi>x</mi>
<mo>=</mo>
<mn>4</mn>
<mrow>
<mo>/</mo>
</mrow>
<mn>5</mn>
</math>
`;
export const moWithGlyphOperator = `
<root>
<math>