diff --git a/bin/units b/bin/units new file mode 100755 index 0000000..4c12226 --- /dev/null +++ b/bin/units @@ -0,0 +1,7 @@ +#!/bin/bash + +# run tests with pipefail to avoid false passes +# see https://github.com/pelias/pelias/issues/744 +set -o pipefail + +node test/run.js | npx tap-spec diff --git a/package.json b/package.json index 966f666..4d21a9e 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "homepage": "https://github.com/pelias/pbf2json", "license": "MIT", "scripts": { - "units": "node test/run.js | tap-spec", + "units": "./bin/units", "test": "npm run units", "pretest": "test/pretest.sh", "end-to-end": "npm run pretest; node test/end-to-end.js;",