summaryrefslogtreecommitdiffstats
path: root/t/t4013-diff-various.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-02-06 01:40:44 +0100
committerJunio C Hamano <gitster@pobox.com>2021-02-06 01:40:44 +0100
commitaac006aa99fd94ac1665d6daa31b9e289914bfe7 (patch)
tree4a7ff0b3a52c0c643ddcaed01fc130310b70b21c /t/t4013-diff-various.sh
parentThe fifth batch (diff)
parentt4013: add tests for --diff-merges=first-parent (diff)
downloadgit-aac006aa99fd94ac1665d6daa31b9e289914bfe7.tar.xz
git-aac006aa99fd94ac1665d6daa31b9e289914bfe7.zip
Merge branch 'so/log-diff-merge'
"git log" learned a new "--diff-merges=<how>" option. * so/log-diff-merge: (32 commits) t4013: add tests for --diff-merges=first-parent doc/git-show: include --diff-merges description doc/rev-list-options: document --first-parent changes merges format doc/diff-generate-patch: mention new --diff-merges option doc/git-log: describe new --diff-merges options diff-merges: add '--diff-merges=1' as synonym for 'first-parent' diff-merges: add old mnemonic counterparts to --diff-merges diff-merges: let new options enable diff without -p diff-merges: do not imply -p for new options diff-merges: implement new values for --diff-merges diff-merges: make -m/-c/--cc explicitly mutually exclusive diff-merges: refactor opt settings into separate functions diff-merges: get rid of now empty diff_merges_init_revs() diff-merges: group diff-merge flags next to each other inside 'rev_info' diff-merges: split 'ignore_merges' field diff-merges: fix -m to properly override -c/--cc t4013: add tests for -m failing to override -c/--cc t4013: support test_expect_failure through ':failure' magic diff-merges: revise revs->diff flag handling diff-merges: handle imply -p on -c/--cc logic for log.c ...
Diffstat (limited to 't/t4013-diff-various.sh')
-rwxr-xr-xt/t4013-diff-various.sh11
1 files changed, 10 insertions, 1 deletions
diff --git a/t/t4013-diff-various.sh b/t/t4013-diff-various.sh
index 45f68ebcdb..ce6aa3914f 100755
--- a/t/t4013-diff-various.sh
+++ b/t/t4013-diff-various.sh
@@ -178,6 +178,7 @@ process_diffs () {
V=$(git version | sed -e 's/^git version //' -e 's/\./\\./g')
while read magic cmd
do
+ status=success
case "$magic" in
'' | '#'*)
continue ;;
@@ -186,6 +187,10 @@ do
label="$magic-$cmd"
case "$magic" in
noellipses) ;;
+ failure)
+ status=failure
+ magic=
+ label="$cmd" ;;
*)
BUG "unknown magic $magic" ;;
esac ;;
@@ -198,7 +203,7 @@ do
expect="$TEST_DIRECTORY/t4013/diff.$test"
actual="$pfx-diff.$test"
- test_expect_success "git $cmd # magic is ${magic:-(not used)}" '
+ test_expect_$status "git $cmd # magic is ${magic:-(not used)}" '
{
echo "$ git $cmd"
case "$magic" in
@@ -326,8 +331,12 @@ log --no-diff-merges -p --first-parent master
log --diff-merges=off -p --first-parent master
log --first-parent --diff-merges=off -p master
log -p --first-parent master
+log -p --diff-merges=first-parent master
+log --diff-merges=first-parent master
log -m -p --first-parent master
log -m -p master
+log --cc -m -p master
+log -c -m -p master
log -SF master
log -S F master
log -SF -p master