aboutsummaryrefslogtreecommitdiff
path: root/t/t6007-rev-list-cherry-pick-file.sh
diff options
context:
space:
mode:
authorStefan Beller <sbeller@google.com>2017-10-06 12:00:06 -0700
committerJunio C Hamano <gitster@pobox.com>2017-10-07 10:56:08 +0900
commit9c5b2fab304b5ce3233401c7c7e7a123d551c484 (patch)
treee53aea6a3b052ed63bd417d6019bf273439f5d7f /t/t6007-rev-list-cherry-pick-file.sh
parent217f2767cbcb562872437eed4dec62e00846d90c (diff)
downloadgit-9c5b2fab304b5ce3233401c7c7e7a123d551c484.tar.gz
git-9c5b2fab304b5ce3233401c7c7e7a123d551c484.tar.xz
tests: fix diff order arguments in test_cmp
Fix the argument order for test_cmp. When given the expected result first the diff shows the actual output with '+' and the expectation with '-', which is the convention for our tests. Signed-off-by: Stefan Beller <sbeller@google.com> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t6007-rev-list-cherry-pick-file.sh')
-rwxr-xr-xt/t6007-rev-list-cherry-pick-file.sh32
1 files changed, 16 insertions, 16 deletions
diff --git a/t/t6007-rev-list-cherry-pick-file.sh b/t/t6007-rev-list-cherry-pick-file.sh
index 295974519..f0268372d 100755
--- a/t/t6007-rev-list-cherry-pick-file.sh
+++ b/t/t6007-rev-list-cherry-pick-file.sh
@@ -57,7 +57,7 @@ test_expect_success '--left-right' '
git rev-list --left-right B...C > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
test_expect_success '--count' '
@@ -77,14 +77,14 @@ test_expect_success '--cherry-pick bar does not come up empty' '
git rev-list --left-right --cherry-pick B...C -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
test_expect_success 'bar does not come up empty' '
git rev-list --left-right B...C -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
cat >expect <<EOF
@@ -96,14 +96,14 @@ test_expect_success '--cherry-pick bar does not come up empty (II)' '
git rev-list --left-right --cherry-pick F...E -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
test_expect_success 'name-rev multiple --refs combine inclusive' '
git rev-list --left-right --cherry-pick F...E -- bar >actual &&
git name-rev --stdin --name-only --refs="*tags/F" --refs="*tags/E" \
<actual >actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
cat >expect <<EOF
@@ -115,7 +115,7 @@ test_expect_success 'name-rev --refs excludes non-matched patterns' '
git rev-list --left-right --cherry-pick F...E -- bar >actual &&
git name-rev --stdin --name-only --refs="*tags/F" \
<actual >actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
cat >expect <<EOF
@@ -127,14 +127,14 @@ test_expect_success 'name-rev --exclude excludes matched patterns' '
git rev-list --left-right --cherry-pick F...E -- bar >actual &&
git name-rev --stdin --name-only --refs="*tags/*" --exclude="*E" \
<actual >actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
test_expect_success 'name-rev --no-refs clears the refs list' '
git rev-list --left-right --cherry-pick F...E -- bar >expect &&
git name-rev --stdin --name-only --refs="*tags/F" --refs="*tags/E" --no-refs --refs="*tags/G" \
<expect >actual &&
- test_cmp actual expect
+ test_cmp expect actual
'
cat >expect <<EOF
@@ -148,7 +148,7 @@ test_expect_success '--cherry-mark' '
git rev-list --cherry-mark F...E -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
cat >expect <<EOF
@@ -162,7 +162,7 @@ test_expect_success '--cherry-mark --left-right' '
git rev-list --cherry-mark --left-right F...E -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
cat >expect <<EOF
@@ -173,14 +173,14 @@ test_expect_success '--cherry-pick --right-only' '
git rev-list --cherry-pick --right-only F...E -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
test_expect_success '--cherry-pick --left-only' '
git rev-list --cherry-pick --left-only E...F -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
cat >expect <<EOF
@@ -192,7 +192,7 @@ test_expect_success '--cherry' '
git rev-list --cherry F...E -- bar > actual &&
git name-rev --stdin --name-only --refs="*tags/*" \
< actual > actual.named &&
- test_cmp actual.named expect
+ test_cmp expect actual.named
'
cat >expect <<EOF
@@ -201,7 +201,7 @@ EOF
test_expect_success '--cherry --count' '
git rev-list --cherry --count F...E -- bar > actual &&
- test_cmp actual expect
+ test_cmp expect actual
'
cat >expect <<EOF
@@ -210,7 +210,7 @@ EOF
test_expect_success '--cherry-mark --count' '
git rev-list --cherry-mark --count F...E -- bar > actual &&
- test_cmp actual expect
+ test_cmp expect actual
'
cat >expect <<EOF
@@ -219,7 +219,7 @@ EOF
test_expect_success '--cherry-mark --left-right --count' '
git rev-list --cherry-mark --left-right --count F...E -- bar > actual &&
- test_cmp actual expect
+ test_cmp expect actual
'
test_expect_success '--cherry-pick with independent, but identical branches' '