Fix tests using new mocha-webpack
This commit is contained in:
@ -4,8 +4,7 @@
|
||||
"description": "Generate .docx documents with JavaScript (formerly Office-Clippy)",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"pretest": "rimraf ./build-tests && tsc -p ./test-tsconfig.json",
|
||||
"test": "mocha ./build-tests --recursive",
|
||||
"test": "mocha-webpack \"src/**/*.ts\"",
|
||||
"prepublishOnly": "npm run build",
|
||||
"lint": "tslint --project .",
|
||||
"build": "npm run webpack",
|
||||
@ -58,6 +57,7 @@
|
||||
"awesome-typescript-loader": "^3.4.1",
|
||||
"chai": "^3.5.0",
|
||||
"mocha": "^3.2.0",
|
||||
"mocha-webpack": "^1.0.1",
|
||||
"prompt": "^1.0.0",
|
||||
"rimraf": "^2.5.2",
|
||||
"shelljs": "^0.7.7",
|
||||
|
@ -26,8 +26,8 @@ describe("LocalPacker", () => {
|
||||
describe("#pack()", () => {
|
||||
it("should create a standard docx file", async function () {
|
||||
this.timeout(99999999);
|
||||
await packer.pack("build-tests/tests/test");
|
||||
fs.statSync("build-tests/tests/test.docx");
|
||||
await packer.pack("build/tests/test");
|
||||
fs.statSync("build/tests/test.docx");
|
||||
});
|
||||
});
|
||||
|
||||
@ -35,8 +35,8 @@ describe("LocalPacker", () => {
|
||||
it("should create a standard PDF file", async function () {
|
||||
this.timeout(99999999);
|
||||
|
||||
await packer.packPdf("build-tests/tests/pdf-test");
|
||||
fs.statSync("build-tests/tests/pdf-test.pdf");
|
||||
await packer.packPdf("build/tests/pdf-test");
|
||||
fs.statSync("build/tests/pdf-test.pdf");
|
||||
});
|
||||
});
|
||||
});
|
||||
|
@ -1,21 +0,0 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"target": "es6",
|
||||
"strictNullChecks": true,
|
||||
"sourceMap": true,
|
||||
"removeComments": true,
|
||||
"preserveConstEnums": true,
|
||||
"outDir": "./build-tests",
|
||||
"sourceRoot": "./src",
|
||||
"rootDir": "./src",
|
||||
"module": "commonjs",
|
||||
"noUnusedLocals": true
|
||||
},
|
||||
"include": [
|
||||
"**/*.spec.ts",
|
||||
"**/*.d.ts"
|
||||
],
|
||||
"exclude": [
|
||||
"node_modules"
|
||||
]
|
||||
}
|
Reference in New Issue
Block a user