Add setting for not justify lines ending in soft line break
This commit is contained in:
@ -60,4 +60,25 @@ describe("Settings", () => {
|
||||
assertSettingsWithUpdateFields(settings);
|
||||
});
|
||||
});
|
||||
describe("#addCompatibility", () => {
|
||||
it("should add an empty Compatibility", () => {
|
||||
const settings = new Settings();
|
||||
settings.addCompatibility();
|
||||
|
||||
const tree = new Formatter().format(settings);
|
||||
let keys: string[] = Object.keys(tree);
|
||||
expect(keys[0]).to.be.equal("w:settings");
|
||||
const rootArray = tree["w:settings"];
|
||||
expect(rootArray).is.an.instanceof(Array);
|
||||
expect(rootArray).has.length(2);
|
||||
keys = Object.keys(rootArray[0]);
|
||||
expect(keys).is.an.instanceof(Array);
|
||||
expect(keys).has.length(1);
|
||||
expect(keys[0]).to.be.equal("_attr");
|
||||
keys = Object.keys(rootArray[1]);
|
||||
expect(keys).is.an.instanceof(Array);
|
||||
expect(keys).has.length(1);
|
||||
expect(keys[0]).to.be.equal("w:compat");
|
||||
});
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user