summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
Diffstat (limited to 't')
-rwxr-xr-xt/t0410-partial-clone.sh15
-rwxr-xr-xt/t3200-branch.sh4
2 files changed, 15 insertions, 4 deletions
diff --git a/t/t0410-partial-clone.sh b/t/t0410-partial-clone.sh
index 463dc3a..6aa0f31 100755
--- a/t/t0410-partial-clone.sh
+++ b/t/t0410-partial-clone.sh
@@ -42,14 +42,25 @@ test_expect_success 'convert shallow clone to partial clone' '
test_cmp_config -C client 1 core.repositoryformatversion
'
-test_expect_success 'convert shallow clone to partial clone must fail with any extension' '
+test_expect_success 'convert to partial clone with noop extension' '
rm -fr server client &&
test_create_repo server &&
test_commit -C server my_commit 1 &&
test_commit -C server my_commit2 1 &&
git clone --depth=1 "file://$(pwd)/server" client &&
test_cmp_config -C client 0 core.repositoryformatversion &&
- git -C client config extensions.partialclone origin &&
+ git -C client config extensions.noop true &&
+ git -C client fetch --unshallow --filter="blob:none"
+'
+
+test_expect_success 'converting to partial clone fails with unrecognized extension' '
+ rm -fr server client &&
+ test_create_repo server &&
+ test_commit -C server my_commit 1 &&
+ test_commit -C server my_commit2 1 &&
+ git clone --depth=1 "file://$(pwd)/server" client &&
+ test_cmp_config -C client 0 core.repositoryformatversion &&
+ git -C client config extensions.nonsense true &&
test_must_fail git -C client fetch --unshallow --filter="blob:none"
'
diff --git a/t/t3200-branch.sh b/t/t3200-branch.sh
index b6aa04b..4c07341 100755
--- a/t/t3200-branch.sh
+++ b/t/t3200-branch.sh
@@ -870,7 +870,7 @@ test_expect_success '--set-upstream-to fails on locked config' '
>.git/config.lock &&
git branch locked &&
test_must_fail git branch --set-upstream-to locked 2>err &&
- test_i18ngrep "could not lock config file .git/config: File exists" err
+ test_i18ngrep "could not lock config file .git/config" err
'
test_expect_success 'use --set-upstream-to modify HEAD' '
@@ -901,7 +901,7 @@ test_expect_success '--unset-upstream should fail if config is locked' '
git branch --set-upstream-to locked &&
>.git/config.lock &&
test_must_fail git branch --unset-upstream 2>err &&
- test_i18ngrep "could not lock config file .git/config: File exists" err
+ test_i18ngrep "could not lock config file .git/config" err
'
test_expect_success 'test --unset-upstream on HEAD' '