Skip to content
Myr

Move sourcing tests to a separate test suite.

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Jordan Harband · committed by Jordan Harband · parent ad0a5cd · Browse files · 8 files+44 added−31 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

8 files+44 added−31 removed

  • tests:+36 added−30 removed
  • other:+8 added−1 removed

8 files+44 added−31 removed

deleted:test/installation/sourcing/setup_dir-8 removed
1#!/bin/sh23mkdir -p ../../../alias45. ../../../nvm.sh6nvm install 0.10.17nvm unload || echo >&2 'nvm unload failed'8
deleted:test/installation/sourcing/Sourcing nvm.sh should use the default if available-17 removed
1#!/bin/sh23die () { echo $@ ; exit 1; }45echo '0.10.1' > ../../../alias/default || die 'creation of default alias failed'67. ../../../nvm.sh || die 'sourcing returned nonzero exit code'89NVM_LS_CURRENT="$(nvm ls current | \grep -o v0.10.1)"10[ "_$NVM_LS_CURRENT" = '_v0.10.1' ] || die "'nvm ls current' did not return '-> v0.10.1', got '$NVM_LS_CURRENT'"1112# NVM_LS_CURRENT_COLORED="$(nvm ls current | sed -n l)"1314NVM_ALIAS_DEFAULT="$(nvm alias default)"15[ "_$NVM_ALIAS_DEFAULT" = "_default -> 0.10.1 (-> v0.10.1)" ] \16 || die "'nvm alias default did not return 'default -> 0.10.1 (-> v0.10.1)', got '$NVM_ALIAS_DEFAULT'"17
deleted:test/installation/sourcing/teardown_dir-5 removed
1#!/bin/sh23rm -rf ../../../alias4rm -rf ../../../v0.10.15
added:test/sourcing/setup+12 added
1#!/bin/sh23mkdir -p ../../alias4rm -f ../../.nvmrc5rm -rf ../../v0.10.76rm -rf ../../v0.9.77rm -rf ../../v0.9.1289. ../../nvm.sh10nvm install 0.10.1 || echo >&2 'nvm install 0.10.1 failed'11nvm unload || echo >&2 'nvm unload failed'12
added:test/sourcing/Sourcing nvm.sh should use the default if available+17 added
1#!/bin/sh23die () { echo $@ ; exit 1; }45echo '0.10.1' > ../../alias/default || die 'creation of default alias failed'67. ../../nvm.sh || die 'sourcing returned nonzero exit code'89NVM_LS_CURRENT="$(nvm ls current | \grep -o v0.10.1)"10[ "_$NVM_LS_CURRENT" = '_v0.10.1' ] || die "'nvm ls current' did not return '-> v0.10.1', got '$NVM_LS_CURRENT'"1112# NVM_LS_CURRENT_COLORED="$(nvm ls current | sed -n l)"1314NVM_ALIAS_DEFAULT="$(nvm alias default)"15[ "_$NVM_ALIAS_DEFAULT" = "_default -> 0.10.1 (-> v0.10.1)" ] \16 || die "'nvm alias default did not return 'default -> 0.10.1 (-> v0.10.1)', got '$NVM_ALIAS_DEFAULT'"17
added:test/sourcing/teardown+7 added
1#!/bin/sh23rm -rf ../../alias4rm -rf ../../v0.10.15rm -rf ../../v0.10.26rm -f ../../.nvmrc7
modified:.travis.yml+6 added
modified:package.json+2 added-1 removed