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

[PATCH] add test case for rebase of empty commit

From
Martin von Zweigbergk <martin.von.zweigbergk@gmail.com>
Date
Jun 27, 2012, 16:22 UTC
Message-ID
<1340814121-23813-1-git-send-email-martin.von.zweigbergk@gmail.com>
---
 t/t3401-rebase-partial.sh |    8 ++++++++
 1 file changed, 8 insertions(+)
diff --git a/t/t3401-rebase-partial.sh b/t/t3401-rebase-partial.sh
index 7ba1797..7f8693b 100755
--- a/t/t3401-rebase-partial.sh
+++ b/t/t3401-rebase-partial.sh
@@ -42,4 +42,12 @@ test_expect_success 'rebase --merge topic branch that was partially merged upstr
 	test_path_is_missing .git/rebase-merge
 '
 
+test_expect_success 'rebase ignores empty commit' '
+	git reset --hard A &&
+	git commit --allow-empty -m empty &&
+	test_commit D &&
+	git rebase C &&
+	test $(git log --format=%s C..) = "D"
+'
+
 test_done
-- 
1.7.9.3.327.g2980b
Next: Junio C Hamano
Message 1 of 8 in “add test case for rebase of empty commit”
  1. add test case for rebase of empty commitMartin von Zweigbergk, Jun 27, 2012
  2. Junio C HamanoJun 27, 2012
  3. Neil HormanJun 28, 2012
  4. Neil HormanJul 3, 2012
  5. Junio C HamanoJul 3, 2012
  6. Neil HormanJul 3, 2012
  7. Junio C HamanoJul 3, 2012
  8. Neil HormanJul 3, 2012

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.