Diff options
| author | Bryce Kwon <bryce@brycekwon.com> | |
|---|---|---|
| committer | Bryce Kwon <bryce@brycekwon.com> | |
| commit | ||
| parent | ||
| tree | ||
| download | ||
Ask for gzip where the tag snapshot needs it
The test ran gzip without the GZIP prerequisite t0110 uses for the same
need, and it took a file-1 anywhere in the listing rather than under the
tag's own prefix.
| -rwxr-xr-x | tests/t0303-robustness.sh | 13 |
1 file changed, 8 insertions, 5 deletions
diff --git a/tests/t0303-robustness.sh b/tests/t0303-robustness.sh index 0a754d7..d9a8809 100755 --- a/tests/t0303-robustness.sh +++ b/tests/t0303-robustness.sh @@ -590,12 +590,15 @@ test_expect_success 'the diff caps hold when the path names a directory' ' ! grep "too large to be rendered inline" tmp ' -test_expect_success 'a snapshot of a tag spelled like an option is archived' ' +test_lazy_prereq GZIP 'command -v gzip' + +test_expect_success GZIP 'a snapshot of a tag spelled like an option is archived' ' git -C repos/rob update-ref refs/tags/-l HEAD && - cgit_rc robrc "url=rob/snapshot/-l.tar.gz" >tmp && - grep "^Status: 200" tmp && - strip_headers <tmp | gzip -dc | tar -tf - >list && - grep "file-1" list + cgit_ok robrc "url=rob/snapshot/-l.tar.gz" >tmp && + strip_headers <tmp >archive.tar.gz && + gzip -dc archive.tar.gz >archive.tar && + tar -tf archive.tar >list && + test_grep "^-l/file-1$" list ' test -n "$CGIT_VALGRIND" || test_set_prereq NO_VALGRIND |
