Skip to content

Commit

Permalink
tests: at-combinations: improve nonsense()
Browse files Browse the repository at this point in the history
In some circumstances 'git log' might fail, but not because the @
parsing failed. For example: 'git rev-parse' might succeed and return a
bad object, and then 'git log' would fail.

The layer we want to test is revision parsing, so let's test that
directly.

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Felipe Contreras authored and Junio C Hamano committed May 8, 2013
1 parent c8a81e9 commit 89d5dd4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion t/t1508-at-combinations.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ check() {

nonsense() {
test_expect_${2:-success} "$1 is nonsensical" "
test_must_fail git log -1 '$1'
test_must_fail git rev-parse --verify '$1'
"
}

Expand Down

0 comments on commit 89d5dd4

Please sign in to comment.