Remove '-e' option from installation tests, in favor of explicit failures.
parent
2f2c6f0727
commit
1931f7f3f8
|
@ -1,6 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
die () { echo $@ ; exit 1; }
|
||||
|
||||
. ../../nvm.sh
|
||||
|
||||
NVM_TEST_VERSION=v0.10.7
|
||||
|
@ -9,9 +10,9 @@ NVM_TEST_VERSION=v0.10.7
|
|||
[ -e ../../$NVM_TEST_VERSION ] && rm -R ../../$NVM_TEST_VERSION
|
||||
|
||||
# Install from binary
|
||||
nvm install $NVM_TEST_VERSION
|
||||
nvm install $NVM_TEST_VERSION || die "install $NVM_TEST_VERSION failed"
|
||||
|
||||
# Check
|
||||
[ -d ../../$NVM_TEST_VERSION ]
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION || die "'nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION' failed"
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
die () { echo $@ ; exit 1; }
|
||||
|
||||
. ../../nvm.sh
|
||||
|
||||
NVM_TEST_VERSION=v0.10.7
|
||||
|
@ -9,9 +10,9 @@ NVM_TEST_VERSION=v0.10.7
|
|||
[ -e ../../$NVM_TEST_VERSION ] && rm -R ../../$NVM_TEST_VERSION
|
||||
|
||||
# Install from source
|
||||
nvm install -s $NVM_TEST_VERSION
|
||||
nvm install -s $NVM_TEST_VERSION || die "'nvm install -s $NVM_TEST_VERSION' failed"
|
||||
|
||||
# Check
|
||||
[ -d ../../$NVM_TEST_VERSION ]
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION || "'nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION' failed"
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
die () { echo $@ ; exit 1; }
|
||||
|
||||
. ../../nvm.sh
|
||||
|
||||
# Remove the stuff we're clobbering.
|
||||
|
@ -8,17 +9,17 @@ set -e
|
|||
[ -e ../../v0.9.12 ] && rm -R ../../v0.9.12
|
||||
|
||||
# Install from binary
|
||||
nvm install 0.9.7
|
||||
nvm i 0.9.12
|
||||
nvm install 0.9.7 || die "'nvm install 0.9.7' failed"
|
||||
nvm i 0.9.12 || die "'nvm i 0.9.12' failed"
|
||||
|
||||
# Check
|
||||
[ -d ../../v0.9.7 ]
|
||||
[ -d ../../v0.9.12 ]
|
||||
[ -d ../../v0.9.7 ] || die "v0.9.7 didn't exist"
|
||||
[ -d ../../v0.9.12 ] || die "v0.9.12 didn't exist"
|
||||
|
||||
# Use the first one
|
||||
nvm use 0.9.7
|
||||
nvm use 0.9.7 || die "'nvm use 0.9.7' failed"
|
||||
|
||||
# Use the latest one
|
||||
nvm use 0.9
|
||||
node --version | grep v0.9.12
|
||||
nvm use 0.9 || die "'nvm use 0.9' failed"
|
||||
node --version | grep v0.9.12 || die "'node --version' was not v0.9.12, got: $(node --version)"
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
die () { echo $@ ; exit 1; }
|
||||
|
||||
. ../../nvm.sh
|
||||
|
||||
NVM_TEST_VERSION=v0.10.7
|
||||
|
@ -11,10 +12,11 @@ NVM_TEST_VERSION=v0.10.7
|
|||
# Install from binary
|
||||
echo "$NVM_TEST_VERSION" > .nvmrc
|
||||
|
||||
nvm install
|
||||
nvm install || die "'nvm install' failed"
|
||||
|
||||
# Check
|
||||
[ -d ../../$NVM_TEST_VERSION ]
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION
|
||||
[ -d ../../$NVM_TEST_VERSION ] || die "./$NVM_TEST_VERSION did not exist"
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION \
|
||||
|| "'nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION' failed"
|
||||
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
die () { echo $@ ; exit 1; }
|
||||
|
||||
. ../../nvm.sh
|
||||
|
||||
NVM_TEST_VERSION=v0.10.7
|
||||
|
@ -11,10 +12,11 @@ NVM_TEST_VERSION=v0.10.7
|
|||
# Install from binary
|
||||
echo "$NVM_TEST_VERSION" > .nvmrc
|
||||
|
||||
nvm install -s
|
||||
nvm install -s || "'nvm install -s' failed"
|
||||
|
||||
# Check
|
||||
[ -d ../../$NVM_TEST_VERSION ]
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION
|
||||
[ -d ../../$NVM_TEST_VERSION ] || die "$NVM_TEST_VERSION did not exist"
|
||||
nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION \
|
||||
|| die "'nvm run $NVM_TEST_VERSION --version | grep $NVM_TEST_VERSION' failed"
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue