Add integration test

This commit is contained in:
Chi Vinh Le
2018-08-31 17:15:40 +02:00
parent 428c35a931
commit 25e8cb517b
8 changed files with 717 additions and 19 deletions
+9
View File
@@ -5,6 +5,15 @@ declare var global: any;
const jsdom = new JSDOM("<!doctype html><html><body></body></html>");
const { window } = jsdom;
// tiny shim for getSelection for the RTE.
// tslint:disable:no-empty
window.getSelection = () =>
({
addRange() {},
removeAllRanges() {},
} as any);
// tslint:enable:no-empty
function copyProps(src: any, target: any) {
const props = Object.getOwnPropertyNames(src)
.filter(prop => typeof target[prop] === "undefined")