docx
Version:
Easily generate .docx files with JS/TS with a nice declarative API. Works for Node and on the Browser.
20 lines (16 loc) • 687 B
text/typescript
// tslint:disable:no-string-literal
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Relationships } from "./relationships";
describe("Relationships", () => {
describe("#constructor()", () => {
it("should create section properties with options", () => {
const properties = new Relationships();
const tree = new Formatter().format(properties);
expect(Object.keys(tree)).to.deep.equal(["Relationships"]);
expect(tree["Relationships"]).to.deep.equal({
_attr: { xmlns: "http://schemas.openxmlformats.org/package/2006/relationships" },
});
});
});
});