Przeglądaj źródła

added test script to redux project

Brandon Wong 7 lat temu
rodzic
commit
cf2f579fce
1 zmienionych plików z 3 dodań i 2 usunięć
  1. 3 2
      redux/package.json

+ 3 - 2
redux/package.json

@@ -3,14 +3,15 @@
   "author": "Brandon Wong",
   "version": "0.1.0",
   "scripts": {
-    "test": "echo \"Error: no test specified\" && exit 1",
+    "test": "node test-build/main.js",
     "compile-prod": "cross-env NODE_ENV=production npm run compile",
     "compile": "npm run compile-src; npm run compile-test; npm run compile-frontend",
     "compile-both": "npm run compile-src; npm run compile-frontend",
     "compile-test": "babel test --out-dir test-build",
     "compile-src": "babel src --out-dir build",
     "compile-frontend": "webpack build/main.js build/bundle.js",
-    "watch": "nodemon --watch src --watch test --watch styles -e js,css,html --exec \"npm run compile --silent\""
+    "watch": "nodemon --watch src --watch test --watch styles -e js,css,html --exec \"npm run compile --silent\"",
+    "testwatch": "nodemon --watch src --watch test --watch styles -e js,css,html --exec \"npm run compile --silent && npm test\""
   },
   "dependencies": {
     "babel-cli": "^6.18.0",