Merge branch 'ma/t1400-undebug-test'
authorJunio C Hamano <gitster@pobox.com>
Tue, 16 Oct 2018 07:16:06 +0000 (16:16 +0900)
committerJunio C Hamano <gitster@pobox.com>
Tue, 16 Oct 2018 07:16:06 +0000 (16:16 +0900)
Test fix.

* ma/t1400-undebug-test:
t1400: drop debug `echo` to actually execute `test`

1  2 
t/t1400-update-ref.sh
diff --combined t/t1400-update-ref.sh
index 663f17c5fe4757a9eea8c749cf1a158a05f4a8df,18bf32aa7eebaafb3c01395893e2e5f3ade5faaa..1fbd94040818ce818c4c7119ee3419620f9c16ff
@@@ -346,7 -346,7 +346,7 @@@ test_expect_success "verifying $m's lo
  
  git update-ref $m $D
  cat >.git/logs/$m <<EOF
 -0000000000000000000000000000000000000000 $C $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150320 -0500
 +$Z $C $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150320 -0500
  $C $A $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150350 -0500
  $A $B $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150380 -0500
  $F $Z $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150680 -0500
@@@ -366,7 -366,7 +366,7 @@@ test_expect_success 'Query master@{2005
        test_when_finished "rm -f o e" &&
        git rev-parse --verify master@{2005-05-25} >o 2>e &&
        test $C = $(cat o) &&
-       echo test "warning: Log for '\''master'\'' only goes back to $ed." = "$(cat e)"
+       test "warning: Log for '\''master'\'' only goes back to $ed." = "$(cat e)"
  '
  test_expect_success 'Query "master@{May 26 2005 23:31:59}" (1 second before history)' '
        test_when_finished "rm -f o e" &&
@@@ -807,37 -807,6 +807,37 @@@ test_expect_success 'stdin delete symre
        test_cmp expect actual
  '
  
 +test_expect_success 'stdin update symref works flag --no-deref' '
 +      git symbolic-ref TESTSYMREFONE $b &&
 +      git symbolic-ref TESTSYMREFTWO $b &&
 +      cat >stdin <<-EOF &&
 +      update TESTSYMREFONE $a $b
 +      update TESTSYMREFTWO $a $b
 +      EOF
 +      git update-ref --no-deref --stdin <stdin &&
 +      git rev-parse TESTSYMREFONE TESTSYMREFTWO >expect &&
 +      git rev-parse $a $a >actual &&
 +      test_cmp expect actual &&
 +      git rev-parse $m~1 >expect &&
 +      git rev-parse $b >actual &&
 +      test_cmp expect actual
 +'
 +
 +test_expect_success 'stdin delete symref works flag --no-deref' '
 +      git symbolic-ref TESTSYMREFONE $b &&
 +      git symbolic-ref TESTSYMREFTWO $b &&
 +      cat >stdin <<-EOF &&
 +      delete TESTSYMREFONE $b
 +      delete TESTSYMREFTWO $b
 +      EOF
 +      git update-ref --no-deref --stdin <stdin &&
 +      test_must_fail git rev-parse --verify -q TESTSYMREFONE &&
 +      test_must_fail git rev-parse --verify -q TESTSYMREFTWO &&
 +      git rev-parse $m~1 >expect &&
 +      git rev-parse $b >actual &&
 +      test_cmp expect actual
 +'
 +
  test_expect_success 'stdin delete ref works with right old value' '
        echo "delete $b $m~1" >stdin &&
        git update-ref --stdin <stdin &&