Change docx folder to more appropriate "file" folder
This commit is contained in:
31
src/file/paragraph/formatting/unordered-list.spec.ts
Normal file
31
src/file/paragraph/formatting/unordered-list.spec.ts
Normal file
@ -0,0 +1,31 @@
|
||||
import { assert } from "chai";
|
||||
|
||||
import { Utility } from "../../../tests/utility";
|
||||
import { NumberProperties } from "./unordered-list";
|
||||
|
||||
describe("NumberProperties", () => {
|
||||
let numberProperties: NumberProperties;
|
||||
|
||||
beforeEach(() => {
|
||||
numberProperties = new NumberProperties(5, 10);
|
||||
});
|
||||
|
||||
describe("#constructor()", () => {
|
||||
it("should create a Number Properties with correct root key", () => {
|
||||
const newJson = Utility.jsonify(numberProperties);
|
||||
assert.equal(newJson.rootKey, "w:numPr");
|
||||
});
|
||||
|
||||
it("should create a Page Break with a Indent Level inside", () => {
|
||||
const newJson = Utility.jsonify(numberProperties);
|
||||
assert.equal(newJson.root[0].rootKey, "w:ilvl");
|
||||
assert.equal(newJson.root[0].root[0].root.val, 10);
|
||||
});
|
||||
|
||||
it("should create a Page Break with a Number Id inside", () => {
|
||||
const newJson = Utility.jsonify(numberProperties);
|
||||
assert.equal(newJson.root[1].rootKey, "w:numId");
|
||||
assert.equal(newJson.root[1].root[0].root.val, 5);
|
||||
});
|
||||
});
|
||||
});
|
Reference in New Issue
Block a user