mirror of
https://github.com/pyenv/pyenv.git
synced 2024-11-14 20:39:55 -05:00
improve versions
tests by cd'ing into a clean slate
This commit is contained in:
parent
05568496c1
commit
bc1049f5ae
1 changed files with 5 additions and 2 deletions
|
@ -6,6 +6,11 @@ create_version() {
|
|||
mkdir -p "${RBENV_ROOT}/versions/$1"
|
||||
}
|
||||
|
||||
setup() {
|
||||
mkdir -p "$RBENV_TEST_DIR"
|
||||
cd "$RBENV_TEST_DIR"
|
||||
}
|
||||
|
||||
@test "no versions installed" {
|
||||
assert [ ! -d "${RBENV_ROOT}/versions" ]
|
||||
run rbenv-versions
|
||||
|
@ -87,8 +92,6 @@ OUT
|
|||
@test "per-project version" {
|
||||
create_version "1.9.3"
|
||||
create_version "2.0.0"
|
||||
mkdir -p "$RBENV_TEST_DIR"
|
||||
cd "$RBENV_TEST_DIR"
|
||||
cat > ".ruby-version" <<<"1.9.3"
|
||||
run rbenv-versions
|
||||
assert_success
|
||||
|
|
Loading…
Reference in a new issue