Simplify npm scripts

This commit is contained in:
Daniel García Aubert 2019-12-02 14:15:40 +01:00
parent b2af93dfec
commit 267557eb90

View File

@ -82,16 +82,10 @@
"pretest:setup": "npm run lint", "pretest:setup": "npm run lint",
"test:setup": "NODE_ENV=test node test setup", "test:setup": "NODE_ENV=test node test setup",
"pretest": "npm run test:setup", "pretest": "npm run test:setup",
"test": "npm run test:all", "test": "NODE_ENV=test mocha -t 5000 --exit --recursive test/acceptance test/integration test/unit",
"test:all": "npm run test:unit && npm run test:integration && npm run test:acceptance",
"test:acceptance": "NODE_ENV=test mocha -t 5000 --exit --recursive test/acceptance",
"test:integration": "NODE_ENV=test mocha --exit --recursive test/integration",
"test:unit": "NODE_ENV=test mocha --exit --recursive test/unit",
"posttest": "npm run test:teardown", "posttest": "npm run test:teardown",
"test:teardown": "NODE_ENV=test node test teardown", "test:teardown": "NODE_ENV=test node test teardown",
"precover": "npm run test:setup", "cover": "nyc --reporter=lcov npm test",
"cover": "NODE_ENV=test nyc --reporter=lcov npm run test:all",
"postcover": "npm run test:teardown",
"test:docker": "docker run -e \"NODEJS_VERSION=$NODE_VERSION\" -v `pwd`:/srv $DOCKER_IMAGE bash docker/scripts/test-setup.sh && docker ps --filter status=dead --filter status=exited -aq | xargs docker rm -v", "test:docker": "docker run -e \"NODEJS_VERSION=$NODE_VERSION\" -v `pwd`:/srv $DOCKER_IMAGE bash docker/scripts/test-setup.sh && docker ps --filter status=dead --filter status=exited -aq | xargs docker rm -v",
"docker:bash": "docker run -it -v `pwd`:/srv $DOCKER_IMAGE bash" "docker:bash": "docker run -it -v `pwd`:/srv $DOCKER_IMAGE bash"
}, },