gpg-interface: allow use of a custom GPG binary
[gitweb.git] / t / t6040-tracking-info.sh
index 4e57dc8cdc423e6c478371d94a304f5bd82e1f41..19272bc551277903bc1c444f4f0f05d8f2d7d672 100755 (executable)
@@ -126,4 +126,18 @@ test_expect_success '--set-upstream does not change branch' '
        grep -q "^refs/heads/master$" actual &&
        cmp expect2 actual2
 '
+
+test_expect_success '--set-upstream @{-1}' '
+       git checkout from-master &&
+       git checkout from-master2 &&
+       git config branch.from-master2.merge > expect2 &&
+       git branch --set-upstream @{-1} follower &&
+       git config branch.from-master.merge > actual &&
+       git config branch.from-master2.merge > actual2 &&
+       git branch --set-upstream from-master follower &&
+       git config branch.from-master.merge > expect &&
+       test_cmp expect2 actual2 &&
+       test_cmp expect actual
+'
+
 test_done