Skip to content

Commit 3cda5b3

Browse files
authored
test: from jasmine to jest (#135)
* test: from jasmine to jest * fix: don't mock setTimeout in tests
1 parent 5f5413d commit 3cda5b3

File tree

2 files changed

+10
-14
lines changed

2 files changed

+10
-14
lines changed

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ install:
1414
- npm install webpack@$WEBPACK_VERSION extract-text-webpack-plugin@$EXTRACT_PLUGIN_VERSION || true
1515

1616
script:
17-
- npm test;
17+
- npm test
1818

1919
after_script:
20-
- './node_modules/.bin/nyc report --reporter=text-lcov > coverage.lcov && ./node_modules/.bin/codecov'
20+
- $(npm bin)/codecov

package.json

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
"description": "webpack plugin for generating asset manifests",
55
"main": "index.js",
66
"scripts": {
7-
"test": "nyc jasmine"
7+
"test": "jest",
8+
"codecov": "codecov"
89
},
910
"author": "Dane Thurber <[email protected]>",
1011
"license": "MIT",
@@ -15,13 +16,12 @@
1516
"webpack": "2 || 3 || 4"
1617
},
1718
"devDependencies": {
18-
"codecov": "^2.2.0",
19+
"codecov": "^2.3.1",
1920
"css-loader": "^0.9.1",
2021
"extract-text-webpack-plugin": "^3.0.2",
2122
"file-loader": "^1.1.11",
22-
"jasmine": "^2.2.1",
23+
"jest": "^22.4.3",
2324
"memory-fs": "^0.2.0",
24-
"nyc": "^10.3.2",
2525
"rimraf": "^2.6.1",
2626
"style-loader": "^0.8.3",
2727
"webpack": "^3.5.2"
@@ -43,13 +43,9 @@
4343
"lodash": ">=3.5 <5",
4444
"tapable": "^1.0.0"
4545
},
46-
"nyc": {
47-
"reporter": [
48-
"lcov",
49-
"text"
50-
],
51-
"exclude": [
52-
"spec"
53-
]
46+
"jest": {
47+
"testEnvironment": "node",
48+
"coverageDirectory": "./coverage/",
49+
"collectCoverage": true
5450
}
5551
}

0 commit comments

Comments
 (0)