1
0
mirror of https://github.com/ianstormtaylor/slate.git synced 2025-08-31 19:01:54 +02:00

Add coverage test with mocha and codecov (#2037)

* Run mocha test with module alias

* Running test with babel module alias

* Fix model alias

* Fix model alias

* Resolve module alias

* Running test with babel module alias

* Connect to codecov

* add codecov to travis

* stop if yarn test has errors

* Still cannot collect data from slate modules

* Try to check whether it works with codecov

* Move config to nycrc

* Remove nyc require

* Update nyc to use src

* better before_script
This commit is contained in:
Jinxuan Zhu
2018-08-06 13:31:42 -04:00
committed by Ian Storm Taylor
parent 07d7f51bbc
commit 58c644323f
88 changed files with 703 additions and 126 deletions

View File

@@ -10,12 +10,16 @@
"babel-eslint": "^8.2.1",
"babel-loader": "^7.1.2",
"babel-plugin-external-helpers": "^6.22.0",
"babel-plugin-istanbul": "^4.1.6",
"babel-plugin-module-resolver": "^3.1.1",
"babel-plugin-transform-runtime": "^6.23.0",
"babel-preset-env": "^1.6.1",
"babel-preset-react": "^6.24.1",
"babel-preset-stage-0": "^6.24.1",
"babel-runtime": "^6.26.0",
"blanket": "^1.2.3",
"chalk": "^1.1.3",
"codecov": "^3.0.4",
"commander": "^2.15.1",
"copy-webpack-plugin": "^4.4.1",
"cross-env": "^5.1.3",
@@ -43,7 +47,9 @@
"lodash": "^4.17.4",
"matcha": "^0.7.0",
"mocha": "^2.5.3",
"mocha-lcov-reporter": "^1.3.0",
"npm-run-all": "^4.1.2",
"nyc": "^12.0.2",
"prettier": "^1.10.2",
"prismjs": "^1.5.1",
"react": "^16.4.1",
@@ -93,13 +99,15 @@
"build:production": "cross-env NODE_ENV=production rollup --config ./support/rollup/config.js && cross-env NODE_ENV=production webpack --config support/webpack/config.js",
"clean": "lerna run clean && rm -rf ./node_modules ./dist ./build",
"gh-pages": "gh-pages --dist ./build",
"lint": "eslint benchmark packages/*/src packages/*/test examples/*/*.js examples/dev/*/*.js && prettier --list-different '**/*.{js,jsx,md,json,css}'",
"lint:eslint": "eslint benchmark packages/*/src packages/*/test examples/*/*.js examples/dev/*/*.js",
"lint:prettier": "prettier --list-different '**/*.{md,json,css}'",
"open": "open http://localhost:8080",
"prettier": "prettier --write '**/*.{js,jsx,md,json,css}'",
"release": "yarn build:production && yarn test && yarn lint && lerna publish && yarn gh-pages",
"server": "webpack-dev-server --config ./support/webpack/config.js",
"start": "npm-run-all --parallel --print-label watch server",
"test": "cross-env BABEL_ENV=test FORBID_DEPRECATIONS=true mocha --require babel-core/register ./packages/*/test/index.js",
"test:coverage": "cross-env NODE_ENV=test nyc yarn test",
"watch": "rollup --config ./support/rollup/config.js --watch"
}
}