summaryrefslogtreecommitdiff
path: root/t/t5505-remote.sh
diff options
context:
space:
mode:
Diffstat (limited to 't/t5505-remote.sh')
-rwxr-xr-xt/t5505-remote.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/t/t5505-remote.sh b/t/t5505-remote.sh
index f1d073f1ba..94079a0e63 100755
--- a/t/t5505-remote.sh
+++ b/t/t5505-remote.sh
@@ -157,6 +157,21 @@ test_expect_success 'rename errors out early when deleting non-existent branch'
)
'
+test_expect_success 'add existing foreign_vcs remote' '
+ test_config remote.foo.vcs bar &&
+ echo "fatal: remote foo already exists." >expect &&
+ test_must_fail git remote add foo bar 2>actual &&
+ test_i18ncmp expect actual
+'
+
+test_expect_success 'add existing foreign_vcs remote' '
+ test_config remote.foo.vcs bar &&
+ test_config remote.bar.vcs bar &&
+ echo "fatal: remote bar already exists." >expect &&
+ test_must_fail git remote rename foo bar 2>actual &&
+ test_i18ncmp expect actual
+'
+
cat >test/expect <<EOF
* remote origin
Fetch URL: $(pwd)/one