[Tests] Replace all dots with backslash dots
parent
2a2b8bdeb3
commit
cadbbced20
2
nvm-exec
2
nvm-exec
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
DIR="$(command cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
DIR="$(command cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||||
|
|
||||||
. "$DIR/nvm.sh" --no-use
|
\. "$DIR/nvm.sh" --no-use
|
||||||
|
|
||||||
if [ -n "$NODE_VERSION" ]; then
|
if [ -n "$NODE_VERSION" ]; then
|
||||||
nvm use $NODE_VERSION > /dev/null || exit 127
|
nvm use $NODE_VERSION > /dev/null || exit 127
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
[ $(nvm alias test-stable-1 | wc -l) = '2' ]
|
[ $(nvm alias test-stable-1 | wc -l) = '2' ]
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
cleanup () {
|
cleanup () {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
. ../../../common.sh
|
\. ../../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../../nvm.sh
|
\. ../../../../nvm.sh
|
||||||
|
|
||||||
ALIAS="$(nvm_resolve_alias loopback | strip_colors)"
|
ALIAS="$(nvm_resolve_alias loopback | strip_colors)"
|
||||||
[ "_$ALIAS" = "_∞" ] || die "nvm_resolve_alias loopback was not ∞; got $ALIAS"
|
[ "_$ALIAS" = "_∞" ] || die "nvm_resolve_alias loopback was not ∞; got $ALIAS"
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
. ../../../common.sh
|
\. ../../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../../nvm.sh
|
\. ../../../../nvm.sh
|
||||||
|
|
||||||
ALIAS="$(nvm_resolve_local_alias loopback | strip_colors)"
|
ALIAS="$(nvm_resolve_local_alias loopback | strip_colors)"
|
||||||
[ "_$ALIAS" = "_∞" ] || die "nvm_resolve_local_alias loopback was not ∞; got $ALIAS"
|
[ "_$ALIAS" = "_∞" ] || die "nvm_resolve_local_alias loopback was not ∞; got $ALIAS"
|
||||||
|
|
|
@ -2,8 +2,8 @@
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
. ../../../../nvm.sh
|
\. ../../../../nvm.sh
|
||||||
. ../../../common.sh
|
\. ../../../common.sh
|
||||||
|
|
||||||
LTS_ALIAS_PATH="$(nvm_alias_path)/lts"
|
LTS_ALIAS_PATH="$(nvm_alias_path)/lts"
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../../nvm.sh
|
\. ../../../../nvm.sh
|
||||||
|
|
||||||
LTS_ALIAS_PATH="$(nvm_alias_path)/lts"
|
LTS_ALIAS_PATH="$(nvm_alias_path)/lts"
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../../nvm.sh
|
\. ../../../../nvm.sh
|
||||||
|
|
||||||
LTS_ALIAS_PATH="$(nvm_alias_path)/lts"
|
LTS_ALIAS_PATH="$(nvm_alias_path)/lts"
|
||||||
|
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm alias default 0.1 >/dev/null || die "'nvm alias default 0.1' failed"
|
nvm alias default 0.1 >/dev/null || die "'nvm alias default 0.1' failed"
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
EXIT_CODE=$(nvm_resolve_alias ; echo $?)
|
EXIT_CODE=$(nvm_resolve_alias ; echo $?)
|
||||||
[ $EXIT_CODE = "1" ] || die "nvm_resolve_alias without an argument did not return 1; got $EXIT_CODE"
|
[ $EXIT_CODE = "1" ] || die "nvm_resolve_alias without an argument did not return 1; got $EXIT_CODE"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
EXIT_CODE=$(nvm_resolve_local_alias ; echo $?)
|
EXIT_CODE=$(nvm_resolve_local_alias ; echo $?)
|
||||||
[ "_$EXIT_CODE" = "_1" ] || die "nvm_resolve_local_alias without an argument did not return 1; got $EXIT_CODE"
|
[ "_$EXIT_CODE" = "_1" ] || die "nvm_resolve_local_alias without an argument did not return 1; got $EXIT_CODE"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir -p "${NVM_DIR}/v0.0.2"
|
mkdir -p "${NVM_DIR}/v0.0.2"
|
||||||
mkdir -p "${NVM_DIR}/v0.0.20"
|
mkdir -p "${NVM_DIR}/v0.0.20"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm which nonexistent_version
|
nvm which nonexistent_version
|
||||||
[ "_$?" = "_1" ]
|
[ "_$?" = "_1" ]
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.0.2"
|
mkdir "${NVM_DIR}/v0.0.2"
|
||||||
mkdir "${NVM_DIR}/v0.0.20"
|
mkdir "${NVM_DIR}/v0.0.20"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.1.3"
|
mkdir "${NVM_DIR}/v0.1.3"
|
||||||
mkdir "${NVM_DIR}/v0.2.3"
|
mkdir "${NVM_DIR}/v0.2.3"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm ls nonexistent_version
|
nvm ls nonexistent_version
|
||||||
[ "$?" = "3" ]
|
[ "$?" = "3" ]
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm ls io
|
nvm ls io
|
||||||
[ "$?" = "3" ]
|
[ "$?" = "3" ]
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm ls node_
|
nvm ls node_
|
||||||
[ "$?" = "3" ]
|
[ "$?" = "3" ]
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir -p "${NVM_DIR}/v0.0.1"
|
mkdir -p "${NVM_DIR}/v0.0.1"
|
||||||
mkdir -p "${NVM_DIR}/v0.0.3"
|
mkdir -p "${NVM_DIR}/v0.0.3"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.0.1"
|
mkdir "${NVM_DIR}/v0.0.1"
|
||||||
mkdir "${NVM_DIR}/v0.0.3"
|
mkdir "${NVM_DIR}/v0.0.3"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.1.3"
|
mkdir "${NVM_DIR}/v0.1.3"
|
||||||
mkdir "${NVM_DIR}/v0.2.3"
|
mkdir "${NVM_DIR}/v0.2.3"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.1.3"
|
mkdir "${NVM_DIR}/v0.1.3"
|
||||||
mkdir "${NVM_DIR}/v0.2.3"
|
mkdir "${NVM_DIR}/v0.2.3"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir -p "${NVM_DIR}/v0.0.1"
|
mkdir -p "${NVM_DIR}/v0.0.1"
|
||||||
mkdir -p "${NVM_DIR}/v0.0.3"
|
mkdir -p "${NVM_DIR}/v0.0.3"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir -p "${NVM_DIR}/versions/node/v0.12.1"
|
mkdir -p "${NVM_DIR}/versions/node/v0.12.1"
|
||||||
mkdir "${NVM_DIR}/v0.1.3"
|
mkdir "${NVM_DIR}/v0.1.3"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.1.2"
|
mkdir "${NVM_DIR}/v0.1.2"
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
nvm alias test v0.1.2
|
nvm alias test v0.1.2
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ set -ex
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
nvm deactivate 2>&1
|
nvm deactivate 2>&1
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
[ `expr $PATH : ".*v0.2.3/.*/bin"` = 0 ] || 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 --delete-prefix v0.2.3 || die "Failed to activate v0.2.3"
|
nvm use --delete-prefix v0.2.3 || die "Failed to activate v0.2.3"
|
||||||
[ `expr "$PATH" : ".*v0.2.3/.*/bin"` != 0 ] || die "PATH not set up properly"
|
[ `expr "$PATH" : ".*v0.2.3/.*/bin"` != 0 ] || die "PATH not set up properly"
|
||||||
|
|
|
@ -7,7 +7,7 @@ cleanup () {
|
||||||
rm -rf "${NVM_DIR}/v0.10.4"
|
rm -rf "${NVM_DIR}/v0.10.4"
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.10.4"
|
mkdir "${NVM_DIR}/v0.10.4"
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ set -ex
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
set +ex # needed for stderr
|
set +ex # needed for stderr
|
||||||
OUTPUT="$(nvm install invalid.invalid 2>&1)"
|
OUTPUT="$(nvm install invalid.invalid 2>&1)"
|
||||||
|
|
|
@ -6,7 +6,7 @@ ALIAS_PATH="../../alias"
|
||||||
|
|
||||||
echo v0.1.2 > "${ALIAS_PATH}/test"
|
echo v0.1.2 > "${ALIAS_PATH}/test"
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
nvm unalias test
|
nvm unalias test
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ set -ex
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
type nvm > /dev/null 2>&1 || die "nvm not loaded"
|
type nvm > /dev/null 2>&1 || die "nvm not loaded"
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ cleanup() {
|
||||||
rm -rf "$(nvm_alias_path)/foo"
|
rm -rf "$(nvm_alias_path)/foo"
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
nvm_make_alias foo foo
|
nvm_make_alias foo foo
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
. ../common.sh
|
\. ../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ cleanup() {
|
||||||
rm -rf "$(nvm_version_path "iojs-${VERSION}")"
|
rm -rf "$(nvm_version_path "iojs-${VERSION}")"
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
nvm deactivate || die "unable to deactivate; current: >$(nvm current)<"
|
nvm deactivate || die "unable to deactivate; current: >$(nvm current)<"
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ cleanup() {
|
||||||
}
|
}
|
||||||
die() { echo $@ ; cleanup ; exit 1; }
|
die() { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
nvm_has_system_node() { return 0; }
|
nvm_has_system_node() { return 0; }
|
||||||
nvm_print_npm_version() { command printf ' (npm v1.2.3)'; }
|
nvm_print_npm_version() { command printf ' (npm v1.2.3)'; }
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
export NVM_SYMLINK_CURRENT=true
|
export NVM_SYMLINK_CURRENT=true
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
rm -rf "${NVM_DIR}/v0.10.29"
|
rm -rf "${NVM_DIR}/v0.10.29"
|
||||||
mkdir "${NVM_DIR}/v0.10.29"
|
mkdir "${NVM_DIR}/v0.10.29"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
TEST_NODE_VERSION="v0.10.29"
|
TEST_NODE_VERSION="v0.10.29"
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
|
|
||||||
nvm
|
nvm
|
||||||
|
|
|
@ -3,5 +3,5 @@
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
set -- yes
|
set -- yes
|
||||||
. ../../nvm.sh
|
\. ../../nvm.sh
|
||||||
[ "$1" = yes ]
|
[ "$1" = yes ]
|
||||||
|
|
|
@ -2,8 +2,8 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
assert_not_ok iojs_version_has_solaris_binary ""
|
assert_not_ok iojs_version_has_solaris_binary ""
|
||||||
assert_not_ok iojs_version_has_solaris_binary "foo"
|
assert_not_ok iojs_version_has_solaris_binary "foo"
|
||||||
|
|
|
@ -2,8 +2,8 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
# Invalid version numbers fail
|
# Invalid version numbers fail
|
||||||
assert_not_ok node_version_has_solaris_binary ""
|
assert_not_ok node_version_has_solaris_binary ""
|
||||||
|
|
|
@ -8,11 +8,11 @@ cleanup() {
|
||||||
unset -f nvm_download nvm_ls_remote nvm_ls_remote_iojs
|
unset -f nvm_download nvm_ls_remote nvm_ls_remote_iojs
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm deactivate 2>/dev/null || die 'unable to deactivate'
|
nvm deactivate 2>/dev/null || die 'unable to deactivate'
|
||||||
|
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
REMOTE="$PWD/mocks/nvm_ls_remote.txt"
|
REMOTE="$PWD/mocks/nvm_ls_remote.txt"
|
||||||
nvm_ls_remote() {
|
nvm_ls_remote() {
|
||||||
|
|
|
@ -8,9 +8,9 @@ cleanup() {
|
||||||
unset -f nvm_remote_version
|
unset -f nvm_remote_version
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
nvm_remote_version() {
|
nvm_remote_version() {
|
||||||
echo "NVM_VERSION_ONLY:${NVM_VERSION_ONLY-},NVM_LTS:${NVM_LTS-},PATTERN:${PATTERN-}"
|
echo "NVM_VERSION_ONLY:${NVM_VERSION_ONLY-},NVM_LTS:${NVM_LTS-},PATTERN:${PATTERN-}"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "_$(nvm_add_iojs_prefix 1)" = "_iojs-v1" ] || die '"nvm_add_iojs_prefix 1" did not return "iojs-v1"'
|
[ "_$(nvm_add_iojs_prefix 1)" = "_iojs-v1" ] || die '"nvm_add_iojs_prefix 1" did not return "iojs-v1"'
|
||||||
[ "_$(nvm_add_iojs_prefix iojs-1)" = "_iojs-v1" ] || die '"nvm_add_iojs_prefix iojs-1" did not return "iojs-v1"'
|
[ "_$(nvm_add_iojs_prefix iojs-1)" = "_iojs-v1" ] || die '"nvm_add_iojs_prefix iojs-1" did not return "iojs-v1"'
|
||||||
|
|
|
@ -6,7 +6,7 @@ cleanup () {
|
||||||
rm -rf ../../../alias/test
|
rm -rf ../../../alias/test
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
OUTPUT="$(nvm_alias 2>&1)"
|
OUTPUT="$(nvm_alias 2>&1)"
|
||||||
EXPECTED_OUTPUT='An alias is required.'
|
EXPECTED_OUTPUT='An alias is required.'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "_$(nvm_alias_path)" = "_$NVM_DIR/alias" ] || die "nvm_alias_path did not requrn correct location"
|
[ "_$(nvm_alias_path)" = "_$NVM_DIR/alias" ] || die "nvm_alias_path did not requrn correct location"
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ cleanup () {
|
||||||
}
|
}
|
||||||
die () { echo $@ ; cleanup; exit 1; }
|
die () { echo $@ ; cleanup; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir -p tmp
|
mkdir -p tmp
|
||||||
touch tmp/emptyfile
|
touch tmp/emptyfile
|
||||||
|
|
|
@ -5,7 +5,7 @@ cleanup () {
|
||||||
}
|
}
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ set -ex
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
set +x
|
set +x
|
||||||
OUTPUT="$(nvm_compute_checksum 2>&1 >/dev/null || echo)"
|
OUTPUT="$(nvm_compute_checksum 2>&1 >/dev/null || echo)"
|
||||||
|
|
|
@ -7,7 +7,7 @@ cleanup () {
|
||||||
}
|
}
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
OUTPUT="$(nvm_die_on_prefix 2>&1)"
|
OUTPUT="$(nvm_die_on_prefix 2>&1)"
|
||||||
EXPECTED_OUTPUT="First argument \"delete the prefix\" must be zero or one"
|
EXPECTED_OUTPUT="First argument \"delete the prefix\" must be zero or one"
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
EXPECTED_OUTPUT="nvm_ensure_default_set: a version is required"
|
EXPECTED_OUTPUT="nvm_ensure_default_set: a version is required"
|
||||||
OUTPUT="$(nvm_ensure_default_set 2>&1 >/dev/null)"
|
OUTPUT="$(nvm_ensure_default_set 2>&1 >/dev/null)"
|
||||||
|
|
|
@ -5,7 +5,7 @@ cleanup () {
|
||||||
rm -rf "$(nvm_version_path v0.1.2)"
|
rm -rf "$(nvm_version_path v0.1.2)"
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir -p "$(nvm_version_path v0.1.2)"
|
mkdir -p "$(nvm_version_path v0.1.2)"
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "_$(nvm_ensure_version_prefix 1)" = "_v1" ] || die '"nvm_ensure_version_prefix 1" did not return "v1"'
|
[ "_$(nvm_ensure_version_prefix 1)" = "_v1" ] || die '"nvm_ensure_version_prefix 1" did not return "v1"'
|
||||||
[ "_$(nvm_ensure_version_prefix v1)" = "_v1" ] || die '"nvm_ensure_version_prefix v1" did not return "v1"'
|
[ "_$(nvm_ensure_version_prefix v1)" = "_v1" ] || die '"nvm_ensure_version_prefix v1" did not return "v1"'
|
||||||
|
|
|
@ -11,7 +11,7 @@ cleanup () {
|
||||||
rm -rf tmp_nvm_find_up
|
rm -rf tmp_nvm_find_up
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
setup
|
setup
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
INPUT="0.1.2"
|
INPUT="0.1.2"
|
||||||
OUTPUT="$(nvm_format_version "$INPUT")"
|
OUTPUT="$(nvm_format_version "$INPUT")"
|
||||||
|
|
|
@ -11,7 +11,7 @@ cleanup() {
|
||||||
|
|
||||||
die () { cleanup; echo $@ ; exit 1; }
|
die () { cleanup; echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
# Directory where mocked binaries used by nvm_get_arch for each OS/arch are
|
# Directory where mocked binaries used by nvm_get_arch for each OS/arch are
|
||||||
# located
|
# located
|
||||||
|
|
|
@ -8,7 +8,7 @@ cleanup () {
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
set +e # TODO: fix
|
set +e # TODO: fix
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
nvm_get_mirror() {
|
nvm_get_mirror() {
|
||||||
|
|
|
@ -4,7 +4,7 @@ set -ex
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
ALG="$(nvm_get_checksum_alg)"
|
ALG="$(nvm_get_checksum_alg)"
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ cleanup() {
|
||||||
unset -f nvm_has
|
unset -f nvm_has
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_has() { return 1 ; }
|
nvm_has() { return 1 ; }
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
expect () {
|
expect () {
|
||||||
INPUT="$1"
|
INPUT="$1"
|
||||||
|
|
|
@ -4,7 +4,7 @@ set -ex
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
! nvm_get_mirror || die 'unknown release type did not error'
|
! nvm_get_mirror || die 'unknown release type did not error'
|
||||||
! nvm_get_mirror node || die 'unknown release type did not error'
|
! nvm_get_mirror node || die 'unknown release type did not error'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_has cat && type cat > /dev/null || die 'nvm_has locates "cat" properly'
|
nvm_has cat && type cat > /dev/null || die 'nvm_has locates "cat" properly'
|
||||||
|
|
||||||
|
|
|
@ -2,8 +2,8 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
# Invalid version numbers fail
|
# Invalid version numbers fail
|
||||||
assert_not_ok nvm_has_solaris_binary ""
|
assert_not_ok nvm_has_solaris_binary ""
|
||||||
|
|
|
@ -7,7 +7,7 @@ cleanup () {
|
||||||
}
|
}
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/versions/io.js/v0.1.2"
|
mkdir "${NVM_DIR}/versions/io.js/v0.1.2"
|
||||||
touch "${NVM_DIR}/versions/io.js/v0.1.2/node"
|
touch "${NVM_DIR}/versions/io.js/v0.1.2/node"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
cleanup () {
|
cleanup () {
|
||||||
rm -rf "${NVM_DIR}/v0.1.2/node"
|
rm -rf "${NVM_DIR}/v0.1.2/node"
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "$(nvm_iojs_prefix)" = "iojs" ] || die '"nvm_iojs_prefix" did not return the string "iojs". why did this fail?!'
|
[ "$(nvm_iojs_prefix)" = "iojs" ] || die '"nvm_iojs_prefix" did not return the string "iojs". why did this fail?!'
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
cleanup () { unalias foo; unalias grep; }
|
cleanup () { unalias foo; unalias grep; }
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
alias foo='bar'
|
alias foo='bar'
|
||||||
nvm_is_alias foo || die '"nvm_is_alias foo" was not true'
|
nvm_is_alias foo || die '"nvm_is_alias foo" was not true'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_is_iojs_version 'iojs-' || die '"nvm_is_iojs_version iojs- was not true'
|
nvm_is_iojs_version 'iojs-' || die '"nvm_is_iojs_version iojs- was not true'
|
||||||
nvm_is_iojs_version 'iojs-foo' || die '"nvm_is_iojs_version iojs- was not true'
|
nvm_is_iojs_version 'iojs-foo' || die '"nvm_is_iojs_version iojs- was not true'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_is_merged_node_version '4.0' || die '"nvm_is_merged_node_version 4.0 was not true'
|
nvm_is_merged_node_version '4.0' || die '"nvm_is_merged_node_version 4.0 was not true'
|
||||||
nvm_is_merged_node_version '5.1' || die '"nvm_is_merged_node_version 5.1 was not true'
|
nvm_is_merged_node_version '5.1' || die '"nvm_is_merged_node_version 5.1 was not true'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
! nvm_is_natural_num || die 'no args is not false'
|
! nvm_is_natural_num || die 'no args is not false'
|
||||||
! nvm_is_natural_num '' || die 'empty string is not false'
|
! nvm_is_natural_num '' || die 'empty string is not false'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_is_valid_version 0.1.2 || die "nvm_is_valid_version 0.1.2 did not return 0"
|
nvm_is_valid_version 0.1.2 || die "nvm_is_valid_version 0.1.2 did not return 0"
|
||||||
nvm_is_valid_version foo && die "nvm_is_valid_version foo did not return 1"
|
nvm_is_valid_version foo && die "nvm_is_valid_version foo did not return 1"
|
||||||
|
|
|
@ -6,7 +6,7 @@ TEST_DIR="$TEST_PWD/nvm_ls_current_tmp"
|
||||||
cleanup() { rm -rf "$TEST_DIR"; unset -f return_zero; alias node='node' ; unalias node; }
|
cleanup() { rm -rf "$TEST_DIR"; unset -f return_zero; alias node='node' ; unalias node; }
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
return_zero () { return 0; }
|
return_zero () { return 0; }
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ cleanup() {
|
||||||
unset -f nvm_download
|
unset -f nvm_download
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
MOCKS_DIR="$PWD/mocks"
|
MOCKS_DIR="$PWD/mocks"
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@ cleanup() {
|
||||||
rm -rf "$TEST_PATH"
|
rm -rf "$TEST_PATH"
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ cleanup() {
|
||||||
unset -f nvm_download
|
unset -f nvm_download
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
# sample output at the time the test was written
|
# sample output at the time the test was written
|
||||||
TAB_PATH="$PWD/mocks/iojs.org-dist-index.tab"
|
TAB_PATH="$PWD/mocks/iojs.org-dist-index.tab"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
OUTPUT="$(nvm_make_alias 2>&1)"
|
OUTPUT="$(nvm_make_alias 2>&1)"
|
||||||
EXIT_CODE="$(nvm_make_alias >/dev/null 2>&1 ; echo $?)"
|
EXIT_CODE="$(nvm_make_alias >/dev/null 2>&1 ; echo $?)"
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "$(nvm_node_prefix)" = "node" ] || die '"nvm_node_prefix" did not return the string "node". why did this fail?!'
|
[ "$(nvm_node_prefix)" = "node" ] || die '"nvm_node_prefix" did not return the string "node". why did this fail?!'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "~$(nvm_num_version_groups)" = "~0" ] || die "no args should give 0"
|
[ "~$(nvm_num_version_groups)" = "~0" ] || die "no args should give 0"
|
||||||
[ "~$(nvm_num_version_groups v)" = "~0" ] || die "just "v" should give 0"
|
[ "~$(nvm_num_version_groups v)" = "~0" ] || die "just "v" should give 0"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
TEST_PATH=/usr/bin:/usr/local/bin
|
TEST_PATH=/usr/bin:/usr/local/bin
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
|
@ -7,7 +7,7 @@ cleanup () {
|
||||||
unset -f nvm_alias nvm_version
|
unset -f nvm_alias nvm_version
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
NVM_ALIAS_DIR='path/to/the alias/dir'
|
NVM_ALIAS_DIR='path/to/the alias/dir'
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
. ../../common.sh
|
\. ../../common.sh
|
||||||
|
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
|
@ -7,7 +7,7 @@ cleanup () {
|
||||||
unset -f nvm_print_implicit_alias nvm_version
|
unset -f nvm_print_implicit_alias nvm_version
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_print_implicit_alias() {
|
nvm_print_implicit_alias() {
|
||||||
echo ''
|
echo ''
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
EXPECTED_FIRST_MSG="nvm_print_implicit_alias must be specified with local or remote as the first argument."
|
EXPECTED_FIRST_MSG="nvm_print_implicit_alias must be specified with local or remote as the first argument."
|
||||||
[ "_$(nvm_print_implicit_alias 2>&1)" = "_$EXPECTED_FIRST_MSG" ] \
|
[ "_$(nvm_print_implicit_alias 2>&1)" = "_$EXPECTED_FIRST_MSG" ] \
|
||||||
|
|
|
@ -13,7 +13,7 @@ cleanup() {
|
||||||
unset -f nvm_ls_remote nvm_ls_remote_iojs
|
unset -f nvm_ls_remote nvm_ls_remote_iojs
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir "${NVM_DIR}/v0.2.3"
|
mkdir "${NVM_DIR}/v0.2.3"
|
||||||
mkdir "${NVM_DIR}/v0.3.4"
|
mkdir "${NVM_DIR}/v0.3.4"
|
||||||
|
|
|
@ -7,7 +7,7 @@ cleanup () {
|
||||||
}
|
}
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_has() { return 1; }
|
nvm_has() { return 1; }
|
||||||
OUTPUT="$(nvm_print_npm_version)"
|
OUTPUT="$(nvm_print_npm_version)"
|
||||||
|
|
|
@ -6,7 +6,7 @@ cleanup() {
|
||||||
unset -f nvm_ls_remote nvm_ls_remote_iojs
|
unset -f nvm_ls_remote nvm_ls_remote_iojs
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_ls_remote() {
|
nvm_ls_remote() {
|
||||||
echo "N/A"
|
echo "N/A"
|
||||||
|
|
|
@ -6,7 +6,7 @@ cleanup() {
|
||||||
unset -f nvm_ls_remote nvm_ls_remote_iojs
|
unset -f nvm_ls_remote nvm_ls_remote_iojs
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
OUTPUT="$(nvm_remote_versions stable 2>&1)"
|
OUTPUT="$(nvm_remote_versions stable 2>&1)"
|
||||||
EXPECTED_OUTPUT="Implicit aliases are not supported in nvm_remote_versions."
|
EXPECTED_OUTPUT="Implicit aliases are not supported in nvm_remote_versions."
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "_$(nvm_strip_iojs_prefix iojs)" = "_" ] || die '"nvm_strip_iojs_prefix iojs" did not return an empty string'
|
[ "_$(nvm_strip_iojs_prefix iojs)" = "_" ] || die '"nvm_strip_iojs_prefix iojs" did not return an empty string'
|
||||||
[ "_$(nvm_strip_iojs_prefix iojs-)" = "_" ] || die '"nvm_strip_iojs_prefix iojs-" did not return an empty string'
|
[ "_$(nvm_strip_iojs_prefix iojs-)" = "_" ] || die '"nvm_strip_iojs_prefix iojs-" did not return an empty string'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
TEST_PATH=$NVM_DIR/v0.10.5/bin:/usr/bin:$NVM_DIR/v0.11.5/bin:$NVM_DIR/v0.9.5/bin:/usr/local/bin:$NVM_DIR/v0.2.5/bin:$NVM_DIR/versions/node/v0.12.0/bin:$NVM_DIR/versions/io.js/v1.0.0/bin
|
TEST_PATH=$NVM_DIR/v0.10.5/bin:/usr/bin:$NVM_DIR/v0.11.5/bin:$NVM_DIR/v0.9.5/bin:/usr/local/bin:$NVM_DIR/v0.2.5/bin:$NVM_DIR/versions/node/v0.12.0/bin:$NVM_DIR/versions/io.js/v1.0.0/bin
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,7 @@ cleanup() {
|
||||||
}
|
}
|
||||||
die () { echo $@ ; cleanup ; exit 1; }
|
die () { echo $@ ; cleanup ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
OLDPATH=$PATH
|
OLDPATH=$PATH
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ cleanup () {
|
||||||
}
|
}
|
||||||
die () { echo $@ ; cleanup; exit 1; }
|
die () { echo $@ ; cleanup; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
mkdir -p tmp
|
mkdir -p tmp
|
||||||
touch tmp/node
|
touch tmp/node
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
EXPECTED_MSG="Only implicit aliases 'stable', 'unstable', 'iojs', and 'node' are supported."
|
EXPECTED_MSG="Only implicit aliases 'stable', 'unstable', 'iojs', and 'node' are supported."
|
||||||
[ "_$(nvm_validate_implicit_alias 2>&1)" = "_$EXPECTED_MSG" ] \
|
[ "_$(nvm_validate_implicit_alias 2>&1)" = "_$EXPECTED_MSG" ] \
|
||||||
|
|
|
@ -5,7 +5,7 @@ cleanup () {
|
||||||
unset -f nvm_ls_current nvm_ls
|
unset -f nvm_ls_current nvm_ls
|
||||||
}
|
}
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_ls_current() {
|
nvm_ls_current() {
|
||||||
echo "CURRENT!"
|
echo "CURRENT!"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
[ "$(nvm_version_dir)" = "$NVM_DIR/versions/node" ] || die '"nvm_version_dir" did not return new dir path'
|
[ "$(nvm_version_dir)" = "$NVM_DIR/versions/node" ] || die '"nvm_version_dir" did not return new dir path'
|
||||||
[ "$(nvm_version_dir iojs)" = "$NVM_DIR/versions/io.js" ] || die '"nvm_version_dir iojs" did not return iojs dir path'
|
[ "$(nvm_version_dir iojs)" = "$NVM_DIR/versions/io.js" ] || die '"nvm_version_dir iojs" did not return iojs dir path'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
die () { echo $@ ; exit 1; }
|
die () { echo $@ ; exit 1; }
|
||||||
|
|
||||||
. ../../../nvm.sh
|
\. ../../../nvm.sh
|
||||||
|
|
||||||
nvm_version_greater 0.10.0 0.2.12 || die '"nvm_version_greater 0.10.0 0.2.12" did not return true'
|
nvm_version_greater 0.10.0 0.2.12 || die '"nvm_version_greater 0.10.0 0.2.12" did not return true'
|
||||||
|
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue