Missed tests
parent
a9be598241
commit
0f709eafa0
|
@ -2,8 +2,12 @@
|
||||||
|
|
||||||
. ../../../nvm.sh
|
. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir ../../../v0.0.{1,3,9}
|
mkdir ../../../v0.0.1
|
||||||
mkdir ../../../v0.3.{1,3,9}
|
mkdir ../../../v0.0.3
|
||||||
|
mkdir ../../../v0.0.9
|
||||||
|
mkdir ../../../v0.3.1
|
||||||
|
mkdir ../../../v0.3.3
|
||||||
|
mkdir ../../../v0.3.9
|
||||||
|
|
||||||
# The result should contain the version numbers.
|
# The result should contain the version numbers.
|
||||||
nvm ls | grep v0.0.1 &&
|
nvm ls | grep v0.0.1 &&
|
||||||
|
|
|
@ -3,4 +3,4 @@
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../nvm.sh
|
. ../../nvm.sh
|
||||||
[[ $(nvm current) == *"current"* ]] || die "Failed to find current version"
|
[ `expr "$(nvm current)" : ".*current"` != 0 ] || die "Failed to find current version"
|
|
@ -4,11 +4,11 @@ mkdir -p ../../v0.2.3
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
[[ $PATH != *v0.2.3/*/bin* ]] || echo "WARNING: Unexpectedly found v0.2.3 already active" >&2
|
[ `expr $PATH : ".*v0.2.3/.*/bin"` == 0 ] || echo "WARNING: Unexpectedly found v0.2.3 already active" >&2
|
||||||
|
|
||||||
. ../../nvm.sh
|
. ../../nvm.sh
|
||||||
nvm use v0.2.3 &&
|
nvm use v0.2.3 &&
|
||||||
[[ $PATH == *v0.2.3/*/bin* ]] || die "Failed to activate v0.2.3"
|
[ `expr $PATH : ".*v0.2.3/.*/bin"` != 0 ] || die "Failed to activate v0.2.3"
|
||||||
|
|
||||||
nvm deactivate &&
|
nvm deactivate &&
|
||||||
[[ $PATH != *v0.2.3/*/bin* ]] || die "Failed to deactivate v0.2.3"
|
[ `expr $PATH : ".*v0.2.3/.*/bin"` != 0 ] || die "Failed to deactivate v0.2.3"
|
||||||
|
|
Loading…
Reference in New Issue