Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRamkumar Ramachandra <artagnon@gmail.com>2011-12-14 20:54:33 +0400
committerJunio C Hamano <gitster@pobox.com>2011-12-16 01:20:19 +0400
commitbf71009e5389aa2f3187ae9c0352ba3c70780f62 (patch)
tree29402e01f632ed14122b555135a85996d47f20e7 /t/t3502-cherry-pick-merge.sh
parentc6b7c7f3050977577af49e5d81340fae3b5bf2e7 (diff)
t3502, t3510: clarify cherry-pick -m failure
The "cherry-pick persists opts correctly" test in t3510 (cherry-pick-sequence) can cause some confusion, because the command actually has two points of failure: 1. "-m 1" is specified on the command-line despite the base commit "initial" not being a merge-commit. 2. The revision range indicates that there will be a conflict that needs to be resolved. Although the former error is trapped, and cherry-pick die()s with the exit status 128, the reader may be distracted by the latter. Fix this by changing the revision range to something that wouldn't cause a conflict. Additionally, explicitly check the exit code in "cherry-pick a non-merge with -m should fail" in t3502 (cherry-pick-merge) to reassure the reader that this failure has nothing to do with the sequencer itself. Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t3502-cherry-pick-merge.sh')
-rwxr-xr-xt/t3502-cherry-pick-merge.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t3502-cherry-pick-merge.sh b/t/t3502-cherry-pick-merge.sh
index 0ab52da902..e37547f41a 100755
--- a/t/t3502-cherry-pick-merge.sh
+++ b/t/t3502-cherry-pick-merge.sh
@@ -35,7 +35,7 @@ test_expect_success 'cherry-pick a non-merge with -m should fail' '
git reset --hard &&
git checkout a^0 &&
- test_must_fail git cherry-pick -m 1 b &&
+ test_expect_code 128 git cherry-pick -m 1 b &&
git diff --exit-code a --
'