git/list[1] front-page[2] threads[3] people[4] search[5] about
wed 2026-10-07 16:55 UTC

[PATCH v3 1/2] t3507: check no CHERRY_PICK_HEAD after conflicting --no-commit

From
Aleksei Sviridkin <f@lex.la>
Date
Sep 5, 2026, 17:13 UTC
Message-ID
<20260905171332.34670-2-f@lex.la>
In-Reply-To
<20260905171332.34670-1-f@lex.la>

Whether CHERRY_PICK_HEAD is written depends on the command, on whether the merge started, and on --no-commit, all in one condition in do_pick_commit(). The suite checks the clean --no-commit pick; nothing checks the conflicting one.

The test that already runs a conflicting --no-commit pick compares the advice the command prints, which is what tells us it stopped on a conflict. Assert the ref is missing there too.

Signed-off-by: Aleksei Sviridkin <f@lex.la>
---
 t/t3507-cherry-pick-conflict.sh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/t/t3507-cherry-pick-conflict.sh b/t/t3507-cherry-pick-conflict.sh
index 44596cb1e8..aa004d929b 100755
--- a/t/t3507-cherry-pick-conflict.sh
+++ b/t/t3507-cherry-pick-conflict.sh
@@ -79,7 +79,8 @@ test_expect_success 'advice from failed cherry-pick --no-commit' "
 	EOF
 	test_must_fail git cherry-pick --no-commit picked 2>actual &&
 
-	test_cmp expected actual
+	test_cmp expected actual &&
+	test_ref_missing CHERRY_PICK_HEAD
 "
 
 test_expect_success 'failed cherry-pick sets CHERRY_PICK_HEAD' '
-- 
2.55.0
Previous: Aleksei SviridkinNext: Aleksei Sviridkin
Message 17 of 21 in “t3507: pin CHERRY_PICK_HEAD absence for a conflicting --no-commit”
  1. 1/2 t3507: pin CHERRY_PICK_HEAD absence for a conflicting --no-commitAleksei Sviridkin, Sep 3, 2026
  2. 2/2 doc: cherry-pick: note --no-commit skips CHERRY_PICK_HEADAleksei Sviridkin, Sep 3, 2026
  3. Junio C HamanoSep 3, 2026
  4. Aleksei SviridkinSep 3, 2026
  5. Patrick SteinhardtSep 4, 2026
  6. Phillip WoodSep 4, 2026
  7. Phillip WoodSep 4, 2026
  8. doc: cherry-pick: note --no-commit skips CHERRY_PICK_HEADAleksei Sviridkin, Sep 4, 2026
  9. Aleksei SviridkinSep 4, 2026
  10. Aleksei SviridkinSep 4, 2026
  11. Phillip WoodSep 4, 2026
  12. Phillip WoodSep 4, 2026
  13. Junio C HamanoSep 4, 2026
  14. Junio C HamanoSep 4, 2026
  15. Junio C HamanoSep 5, 2026
  16. 0/2 cherry-pick: document that --no-commit skips CHERRY_PICK_HEADAleksei Sviridkin, Sep 5, 2026
  17. 1/2 t3507: check no CHERRY_PICK_HEAD after conflicting --no-commitAleksei Sviridkin, Sep 5, 2026
  18. 2/2 doc: cherry-pick: note --no-commit skips CHERRY_PICK_HEADAleksei Sviridkin, Sep 5, 2026
  19. Aleksei SviridkinSep 5, 2026
  20. Aleksei SviridkinSep 5, 2026
  21. Aleksei SviridkinSep 5, 2026

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.