1
0
mirror of https://github.com/pyenv/pyenv.git synced 2025-11-16 23:33:45 -05:00

Simplify resolving symlinks, remove native extension (#1428)

This commit is contained in:
Mislav Marohnić
2022-09-22 11:34:02 +02:00
committed by GitHub
parent 56a440e4a7
commit 117a381575
13 changed files with 27 additions and 864 deletions

View File

@@ -43,16 +43,16 @@ ${RBENV_TEST_DIR}/etc/rbenv hooks/exec/ahoy.bash
OUT
}
@test "resolves relative paths" {
@test "does not canonicalize paths" {
RBENV_HOOK_PATH="${RBENV_TEST_DIR}/rbenv.d"
create_hook exec "hello.bash"
mkdir -p "$HOME"
RBENV_HOOK_PATH="${HOME}/../rbenv.d" run rbenv-hooks exec
assert_success "${RBENV_TEST_DIR}/rbenv.d/exec/hello.bash"
assert_success "${RBENV_TEST_DIR}/home/../rbenv.d/exec/hello.bash"
}
@test "resolves symlinks" {
@test "does not resolve symlinks" {
path="${RBENV_TEST_DIR}/rbenv.d"
mkdir -p "${path}/exec"
mkdir -p "$HOME"
@@ -64,7 +64,7 @@ OUT
RBENV_HOOK_PATH="$path" run rbenv-hooks exec
assert_success
assert_output <<OUT
${HOME}/hola.bash
${RBENV_TEST_DIR}/rbenv.d/exec/bright.sh
${RBENV_TEST_DIR}/rbenv.d/exec/hello.bash
${RBENV_TEST_DIR}/rbenv.d/exec/world.bash
OUT
}