Files
docx-js/src/file/paragraph/math/n-ary/math-naray-properties.spec.ts

34 lines
1.0 KiB
TypeScript
Raw Normal View History

2019-08-20 20:40:40 +01:00
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { MathNArayProperties } from "./math-naray-properties";
describe("MathNArayProperties", () => {
describe("#constructor()", () => {
it("should create a MathNArayProperties with correct root key", () => {
const mathNArayProperties = new MathNArayProperties("∑");
const tree = new Formatter().format(mathNArayProperties);
expect(tree).to.deep.equal({
"m:naryPr": [
{
"m:chr": {
_attr: {
"m:val": "∑",
},
},
},
{
"m:limLoc": {
_attr: {
"m:val": "undOvr",
},
},
},
],
});
});
});
});