Skip to content

Commit

Permalink
bash prompt: add a test for symbolic link symbolic refs
Browse files Browse the repository at this point in the history
Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
  • Loading branch information
SZEDER Gábor committed Jun 24, 2013
1 parent c9a102e commit 868dc1a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions t/t9903-bash-prompt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@ test_expect_success 'prompt - branch name' '
test_cmp expected "$actual"
'

test_expect_success SYMLINKS 'prompt - branch name - symlink symref' '
printf " (master)" >expected &&
test_when_finished "git checkout master" &&
test_config core.preferSymlinkRefs true &&
git checkout master &&
__git_ps1 >"$actual" &&
test_cmp expected "$actual"
'

test_expect_success 'prompt - detached head' '
printf " ((%s...))" $(git log -1 --format="%h" b1^) >expected &&
git checkout b1^ &&
Expand Down

0 comments on commit 868dc1a

Please sign in to comment.