mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-08-16 10:43:42 +00:00
Compare commits
3 Commits
65286687cf
...
5636b5247a
Author | SHA1 | Date | |
---|---|---|---|
![]() |
5636b5247a | ||
![]() |
762f9ef9d1 | ||
![]() |
639aaf9cd5 |
@ -32,7 +32,7 @@ before_install:
|
||||
- zsh --version
|
||||
- dpkg -s dash | grep ^Version | awk '{print $2}'
|
||||
# install python
|
||||
- pyenv install 2.7.18
|
||||
- pyenv local 2.7.18 || pyenv install 2.7.18
|
||||
- pyenv local 2.7.18 || echo 'pyenv failed'
|
||||
- python -V
|
||||
install:
|
||||
|
26
test/slow/nvm run/Running 'nvm run --silent' should work
Executable file
26
test/slow/nvm run/Running 'nvm run --silent' should work
Executable file
@ -0,0 +1,26 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -ex
|
||||
|
||||
die () { echo $@ ; exit 1; }
|
||||
|
||||
. ../../../nvm.sh
|
||||
|
||||
echo "0.10.7" > .nvmrc
|
||||
|
||||
# Check nvm run without --silent
|
||||
OUTPUT="$(nvm run --version | awk '{print $6}' | head -1)"
|
||||
EXPECTED_OUTPUT="<0.10.7>"
|
||||
[ "${OUTPUT}" = "${EXPECTED_OUTPUT}" ] \
|
||||
|| die "\`nvm run\` failed to run; did not match with the .nvmrc version; got >${OUTPUT}<"
|
||||
|
||||
OUTPUT="$(nvm run --silent --version)"
|
||||
EXPECTED_OUTPUT=""
|
||||
[ "${OUTPUT}" = "${EXPECTED_OUTPUT}" ] \
|
||||
|| die "\`nvm run --silent\` failed to run silently; expected no output, got >${OUTPUT}<"
|
||||
|
||||
# Output shouldn't be silent if --silent flag is not at the third argument position
|
||||
OUTPUT="$(nvm run --version --silent)"
|
||||
EXPECTED_OUTPUT=""
|
||||
[ "${OUTPUT}" != "${EXPECTED_OUTPUT}" ] \
|
||||
|| die "\`nvm run --version --silent\` should not be silent; expected >${OUTPUT}<, got no output"
|
Loading…
x
Reference in New Issue
Block a user