test: add mtext monospace text use case

This commit is contained in:
Alexandre Nunes 2020-09-17 11:45:54 -03:00
parent 99594e8b53
commit 5c8e26920d

@ -1459,6 +1459,20 @@ describe('#convert', () => {
expect(result).toBe('\\mathfrak{Creepy}'); expect(result).toBe('\\mathfrak{Creepy}');
}); });
describe('mtext with mathvariant attribute setted as "monospace"', () => {
const mathml = `
<root>
<math xmlns = "http://www.w3.org/1998/Math/MathML">
<mtext mathvariant="monospace">simple text</mtext>
</math>
</root>
`;
const result = MathMLToLaTeX.convert(mathml);
expect(result).toBe('\\mathtt{simple text}');
});
describe('mtext with mathvariant attribute setted as "script"', () => { describe('mtext with mathvariant attribute setted as "script"', () => {
const mathml = ` const mathml = `
<root> <root>