summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: fc6fa0d)
raw | patch | inline | side by side (parent: fc6fa0d)
author | Tay Ray Chuan <rctay89@gmail.com> | |
Thu, 27 May 2010 15:34:51 +0000 (23:34 +0800) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Fri, 28 May 2010 22:35:23 +0000 (15:35 -0700) |
After c197702 (pretty: Respect --abbrev option), non-abbreviated hashes
began to appear, leading to failures for these tests.
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
began to appear, leading to failures for these tests.
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t7502-commit.sh | patch | blob | history |
diff --git a/t/t7502-commit.sh b/t/t7502-commit.sh
index 478b637b0c82fa7145bfbf4297e1fa14bd118271..b10541d4d31030f743293df14e37eac0b677248e 100755 (executable)
--- a/t/t7502-commit.sh
+++ b/t/t7502-commit.sh
. ./test-lib.sh
-# Arguments: [<prefix] [<commit message>]
+# Arguments: [<prefix] [<commit message>] [<commit options>]
check_summary_oneline() {
test_tick &&
- git commit -m "$2" | head -1 > act &&
+ git commit ${3+"$3"} -m "$2" | head -1 > act &&
# branch name
SUMMARY_PREFIX="$(git name-rev --name-only HEAD)" &&
check_summary_oneline "" "a change"
'
+test_expect_failure 'output summary format for commit with an empty diff' '
+
+ check_summary_oneline "" "empty" "--allow-empty"
+'
+
+test_expect_failure 'output summary format for merges' '
+
+ git checkout -b recursive-base &&
+ test_commit base file1 &&
+
+ git checkout -b recursive-a recursive-base &&
+ test_commit commit-a file1 &&
+
+ git checkout -b recursive-b recursive-base &&
+ test_commit commit-b file1 &&
+
+ # conflict
+ git checkout recursive-a &&
+ test_must_fail git merge recursive-b &&
+ # resolve the conflict
+ echo commit-a > file1 &&
+ git add file1 &&
+ check_summary_oneline "" "Merge"
+'
+
output_tests_cleanup() {
# this is needed for "do not fire editor in the presence of conflicts"
git checkout master &&