diff options
author | Leonid <logvinov.leon@gmail.com> | 2017-06-06 20:04:14 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-06-06 20:04:14 +0800 |
commit | 0b700deb01ea044d53ae80ee483aa75262dcff07 (patch) | |
tree | 738b5aac18f18c40b5b4152f8c8fe70811c03af6 | |
parent | bf66a43ca81f799446fe031a972721f4352470b5 (diff) | |
parent | 899de0b94f6dee75ea1e3934620ce8c108aea65b (diff) | |
download | dexon-0x-contracts-0b700deb01ea044d53ae80ee483aa75262dcff07.tar.gz dexon-0x-contracts-0b700deb01ea044d53ae80ee483aa75262dcff07.tar.zst dexon-0x-contracts-0b700deb01ea044d53ae80ee483aa75262dcff07.zip |
Merge pull request #37 from 0xProject/umd-ci
Add script to run UMD tests
-rw-r--r-- | package.json | 2 | ||||
-rwxr-xr-x | scripts/test_umd.sh | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/package.json b/package.json index 334f353dc..26ae8a504 100644 --- a/package.json +++ b/package.json @@ -14,7 +14,7 @@ "build": "run-p build:*:prod", "lint": "tslint src/*.ts test/*.ts", "test": "run-s clean test:commonjs", - "test:umd": "run-s substitute_umd_bundle run_mocha; npm run clean", + "test:umd": "./scripts/test_umd.sh", "test:coverage": "nyc npm run test --all", "update_contracts": "for i in ${npm_package_config_artifacts}; do copyfiles -u 4 ../contracts/build/contracts/$i.json ../0x.js/src/artifacts; done;", "testrpc": "testrpc -p 8545 --networkId 50 -m \"${npm_package_config_mnemonic}\"", diff --git a/scripts/test_umd.sh b/scripts/test_umd.sh new file mode 100755 index 000000000..d200c76d0 --- /dev/null +++ b/scripts/test_umd.sh @@ -0,0 +1,7 @@ +#!/usr/bin/env bash +# This script runs umd tests and cleans up after them while preserving the `return_code` for CI +# UMD tests should only be run after building the commonjs because they reuse some of the commonjs build artifacts +run-s substitute_umd_bundle run_mocha +return_code=$? +npm run clean +exit $return_code |