diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-20 05:14:39 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-20 05:14:39 +0000 |
commit | 7260c37aa8c91c8008dcd2442a19c23d1c9040fb (patch) | |
tree | 83953428f11212a71a4616e535c1053076f9bb94 /t/t1091-sparse-checkout-builtin.sh | |
parent | Releasing progress-linux version 1:2.43.0-1~progress7.99u1. (diff) | |
download | git-7260c37aa8c91c8008dcd2442a19c23d1c9040fb.tar.xz git-7260c37aa8c91c8008dcd2442a19c23d1c9040fb.zip |
Merging upstream version 1:2.45.1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 't/t1091-sparse-checkout-builtin.sh')
-rwxr-xr-x | t/t1091-sparse-checkout-builtin.sh | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/t/t1091-sparse-checkout-builtin.sh b/t/t1091-sparse-checkout-builtin.sh index f67611d..ab3a105 100755 --- a/t/t1091-sparse-checkout-builtin.sh +++ b/t/t1091-sparse-checkout-builtin.sh @@ -334,7 +334,7 @@ test_expect_success 'cone mode: set with nested folders' ' test_expect_success 'cone mode: add independent path' ' git -C repo sparse-checkout set deep/deeper1 && - git -C repo sparse-checkout add folder1 && + git -C repo sparse-checkout add --end-of-options folder1 && cat >expect <<-\EOF && /* !/*/ @@ -886,6 +886,12 @@ test_expect_success 'by default, cone mode will error out when passed files' ' grep ".gitignore.*is not a directory" error ' +test_expect_success 'error on mistyped command line options' ' + test_must_fail git -C repo sparse-checkout add --sikp-checks .gitignore 2>error && + + grep "unknown option.*sikp-checks" error +' + test_expect_success 'by default, non-cone mode will warn on individual files' ' git -C repo sparse-checkout reapply --no-cone && git -C repo sparse-checkout add .gitignore 2>warning && @@ -962,7 +968,7 @@ test_expect_success 'check-rules non-cone mode' ' git -C bare sparse-checkout check-rules --no-cone --rules-file ../rules\ >check-rules-file <all-files && - cat rules | git -C repo sparse-checkout set --no-cone --stdin && + git -C repo sparse-checkout set --no-cone --stdin <rules && git -C repo ls-files -t >out && sed -n "/^S /!s/^. //p" out >ls-files && |