Add math run and fraction
This commit is contained in:
21
src/file/paragraph/math/math-run.spec.ts
Normal file
21
src/file/paragraph/math/math-run.spec.ts
Normal file
@ -0,0 +1,21 @@
|
||||
import { expect } from "chai";
|
||||
|
||||
import { Formatter } from "export/formatter";
|
||||
|
||||
import { MathRun } from "./math-run";
|
||||
|
||||
describe("MathRun", () => {
|
||||
describe("#constructor()", () => {
|
||||
it("should create a MathRun with correct root key", () => {
|
||||
const mathRun = new MathRun("2+2");
|
||||
const tree = new Formatter().format(mathRun);
|
||||
expect(tree).to.deep.equal({
|
||||
"m:r": [
|
||||
{
|
||||
"m:t": ["2+2"],
|
||||
},
|
||||
],
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
Reference in New Issue
Block a user