git/list[1] front-page[2] threads[3] people[4] search[5] about
 

git-merge adds test to a message -- bug?

From
JSJörg Sommer <joerg@alea.gnuu.de>
Date
Mar 23, 2008, 23:13 UTC
Message-ID
<slrnfudp0q.19k.joerg@alea.gnuu.de>
Hi,
is it correct, that this test fails?
diff --git a/t/t6032-merge-message.sh b/t/t6032-merge-message.sh
new file mode 100755
index 0000000..97157bd
--- /dev/null
+++ b/t/t6032-merge-message.sh
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+test_description='test for merge message'
+
+. ./test-lib.sh
+
+test_expect_success setup '
+	: > file1 &&
+	git add file1 &&
+        test_tick &&
+	git commit -m "commit 1" &&
+	: > file2 &&
+	git add file2 &&
+        test_tick &&
+	git commit -m "commit 2" &&
+
+	git checkout -b new-branch HEAD~1 &&
+	: > file3 &&
+	git add file3 &&
+        test_tick &&
+	git commit -m "commit 3"
+'
+
+test_expect_success merge 'git merge -m master-merge master'
+
+test_expect_failure 'merge message check' '
+	test "$(git cat-file commit HEAD | sed "1,/^\$/d")" = master-merge
+'
+
+test_done

Bye, Jörg.
-- 
Unsere Zweifel sind Verräter und oft genug verspielen wir den möglichen
Gewinn, weil wir den Versuch nicht wagen.
Next: Junio C Hamano
Message 1 of 7 in “git-merge adds test to a message -- bug?”
  1. Jörg SommerMar 23, 2008
  2. Junio C HamanoMar 24, 2008
  3. Johannes SchindelinMar 24, 2008
  4. Junio C HamanoMar 24, 2008
  5. Jörg SommerMar 25, 2008
  6. Johannes SchindelinMar 25, 2008
  7. Jörg SommerApr 9, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.