From 373a67b4a30779032f890a8106c065b53ffe0d19 Mon Sep 17 00:00:00 2001 From: "Michael Bradley, Jr" Date: Thu, 6 Sep 2018 22:43:52 -0500 Subject: [PATCH] rev testdapp scripts -- INIT_CWD compat --- package.json | 11 ++++++----- test_apps/contracts_app/package.json | 3 ++- test_apps/coverage_app/package.json | 5 +++-- test_apps/test_app/package.json | 3 ++- 4 files changed, 13 insertions(+), 9 deletions(-) diff --git a/package.json b/package.json index 120e31372..a24c45d31 100644 --- a/package.json +++ b/package.json @@ -3,11 +3,12 @@ "version": "3.2.0-develop", "description": "Embark is a framework that allows you to easily develop and deploy DApps", "scripts": { - "lint": "./node_modules/.bin/eslint lib/", - "test": "mocha test/ --no-timeouts --exit", - "testdapp_1": "cd test_apps/test_app/ && npm install && node ../../bin/embark test", - "testdapp_2": "cd test_apps/contracts_app/ && npm install && node ../../bin/embark test", - "fulltest": "npm run lint && npm run test && npm run testdapp_1 && npm run testdapp_2" + "lint": "eslint lib/", + "test": "npm-run-all lint test:*", + "test:embark": "mocha test/ --no-timeouts --exit", + "test:test_app": "cross-env DAPP=\"test_app\" npm run test_dapp", + "test:contracts_app": "cross-env DAPP=\"contracts_app\" npm run test_dapp", + "test_dapp": "cross-env-shell \"cd test_apps/$DAPP && npm install && npm test\"" }, "bin": { "embark": "./bin/embark" diff --git a/test_apps/contracts_app/package.json b/test_apps/contracts_app/package.json index 5a6a3beea..eef4bc35b 100644 --- a/test_apps/contracts_app/package.json +++ b/test_apps/contracts_app/package.json @@ -4,7 +4,8 @@ "description": "", "main": "Gruntfile.js", "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" + "embark": "node ../../bin/embark", + "test": "npm run embark test" }, "author": "", "license": "ISC", diff --git a/test_apps/coverage_app/package.json b/test_apps/coverage_app/package.json index 8020497c0..6198d0af2 100644 --- a/test_apps/coverage_app/package.json +++ b/test_apps/coverage_app/package.json @@ -4,8 +4,9 @@ "description": "", "main": "Gruntfile.js", "scripts": { - "test": "../../bin/embark test", - "coverage": "istanbul report --root .embark --format html" + "coverage": "istanbul report --root .embark --format html", + "embark": "node ../../bin/embark", + "test": "npm run embark test" }, "author": "", "license": "ISC", diff --git a/test_apps/test_app/package.json b/test_apps/test_app/package.json index 586d6be88..687d7b98b 100644 --- a/test_apps/test_app/package.json +++ b/test_apps/test_app/package.json @@ -4,7 +4,8 @@ "description": "", "main": "Gruntfile.js", "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" + "embark": "node ../../bin/embark", + "test": "npm run embark test" }, "author": "", "license": "ISC",