Skip to content

Commit

Permalink
t7501-commit: Add test for git commit <file> with dirty index.
Browse files Browse the repository at this point in the history
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Kristian Høgsberg authored and Junio C Hamano committed Nov 23, 2007
1 parent 18abc2d commit 1200993
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions t/t7501-commit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -257,4 +257,14 @@ test_expect_success 'amend commit to fix author' '
diff expected current
'

test_expect_success 'git commit <file> with dirty index' '
echo tacocat > elif &&
echo tehlulz > chz &&
git add chz &&
git commit elif -m "tacocat is a palindrome" &&
git show --stat | grep elif &&
git diff --cached | grep chz
'

test_done

0 comments on commit 1200993

Please sign in to comment.