diff options
Diffstat (limited to 'test/tests/link-canonicalize.bash')
-rw-r--r-- | test/tests/link-canonicalize.bash | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/tests/link-canonicalize.bash b/test/tests/link-canonicalize.bash new file mode 100644 index 0000000..34015c8 --- /dev/null +++ b/test/tests/link-canonicalize.bash @@ -0,0 +1,20 @@ +test_description='linking canonicalizes path by default' +. '../test-lib.bash' + +test_expect_success 'setup' ' +echo "apple" > ${DOTFILES}/f && +ln -s dotfiles dotfiles-symlink +' + +test_expect_success 'run' ' +cat > "${DOTFILES}/${INSTALL_CONF}" <<EOF +- link: + ~/.f: + path: f +EOF +${DOTBOT_EXEC} -c dotfiles-symlink/${INSTALL_CONF} +' + +test_expect_success 'test' ' +[ "$(readlink ~/.f | cut -d/ -f4-)" = "dotfiles/f" ] +' |