mirror of
https://github.com/rbenv/rbenv.git
synced 2024-12-29 13:15:42 +01:00
29 lines
571 B
Bash
29 lines
571 B
Bash
#!/usr/bin/env bats
|
|
|
|
load test_helper
|
|
|
|
@test "no shims" {
|
|
run rbenv-shims
|
|
assert_success
|
|
assert [ -z "$output" ]
|
|
}
|
|
|
|
@test "shims" {
|
|
mkdir -p "${RBENV_ROOT}/shims"
|
|
touch "${RBENV_ROOT}/shims/ruby"
|
|
touch "${RBENV_ROOT}/shims/irb"
|
|
run rbenv-shims
|
|
assert_success
|
|
assert_line "${RBENV_ROOT}/shims/ruby"
|
|
assert_line "${RBENV_ROOT}/shims/irb"
|
|
}
|
|
|
|
@test "shims --short" {
|
|
mkdir -p "${RBENV_ROOT}/shims"
|
|
touch "${RBENV_ROOT}/shims/ruby"
|
|
touch "${RBENV_ROOT}/shims/irb"
|
|
run rbenv-shims --short
|
|
assert_success
|
|
assert_line "irb"
|
|
assert_line "ruby"
|
|
}
|