2017-03-07 22:15:53 +00:00
|
|
|
import { assert } from "chai";
|
2017-09-17 00:00:41 +01:00
|
|
|
|
|
|
|
import { Utility } from "../../tests/utility";
|
|
|
|
import { DoubleStrike, Strike } from "./formatting";
|
2016-07-18 19:17:19 +01:00
|
|
|
|
|
|
|
describe("Strike", () => {
|
|
|
|
let strike: Strike;
|
|
|
|
|
|
|
|
beforeEach(() => {
|
|
|
|
strike = new Strike();
|
|
|
|
});
|
|
|
|
|
|
|
|
describe("#constructor()", () => {
|
|
|
|
it("should create a Strike with correct root key", () => {
|
2017-03-09 22:56:08 +00:00
|
|
|
const newJson = Utility.jsonify(strike);
|
2016-07-18 19:17:19 +01:00
|
|
|
assert.equal(newJson.rootKey, "w:strike");
|
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
describe("DoubleStrike", () => {
|
|
|
|
let strike: DoubleStrike;
|
|
|
|
|
|
|
|
beforeEach(() => {
|
|
|
|
strike = new DoubleStrike();
|
|
|
|
});
|
|
|
|
|
|
|
|
describe("#constructor()", () => {
|
|
|
|
it("should create a Double Strike with correct root key", () => {
|
2017-03-09 22:56:08 +00:00
|
|
|
const newJson = Utility.jsonify(strike);
|
2016-07-18 19:17:19 +01:00
|
|
|
assert.equal(newJson.rootKey, "w:dstrike");
|
|
|
|
});
|
|
|
|
});
|
2017-03-09 22:56:08 +00:00
|
|
|
});
|