notes: add tests for --commit/--abort/--strategy exclusivity
Add new tests to ensure that --commit, --abort, and --strategy are mutually exclusive. Signed-off-by: Jacob Keller <jacob.keller@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Jacob Keller committed
Aug 17, 2015 at 14:33 UTC
11dd2b2e9a3303bd1e32fd2ee95ec5dff38d9d47
1 file changed
+12
t/t3310-notes-merge-manual-resolve.sh
+12
@@ -314,6 +314,18 @@ y and z notes on 1st commit
314
315
EOF
316
317
+test_expect_success 'do not allow mixing --commit and --abort' '
318
+ test_must_fail git notes merge --commit --abort
319
+'
320
+
321
+test_expect_success 'do not allow mixing --commit and --strategy' '
322
+ test_must_fail git notes merge --commit --strategy theirs
323
+'
324
+
325
+test_expect_success 'do not allow mixing --abort and --strategy' '
326
+ test_must_fail git notes merge --abort --strategy theirs
327
+'
328
+
329
test_expect_success 'finalize conflicting merge (z => m)' '
330
# Resolve conflicts and finalize merge
331
cat >.git/NOTES_MERGE_WORKTREE/$commit_sha1 <<EOF &&