git/t/helper
Jeff Hostetler 192eeda948 t5799: add tests to detect corrupt pack/idx files in prefetch
Add "mayhem" keys to generate corrupt packfiles and/or corrupt idx
files in prefetch by trashing the trailing checksum SHA.

Add unit tests to t5799 to verify that `gvfs-helper` detects these
corrupt pack/idx files.

Currently, only the (bad-pack, no-idx) case is correctly detected,
Because `gvfs-helper` needs to locally compute the idx file itself.

A test for the (bad-pack, any-idx) case was also added (as a known
breakage) because `gvfs-helper` assumes that when the cache server
provides both, it doesn't need to verify them.  We will fix that
assumption in the next commit.

Signed-off-by: Jeff Hostetler <jeffhostetler@github.com>
2023-04-17 11:27:47 -04:00
..
.gitignore gvfs-helper: create tool to fetch objects using the GVFS Protocol 2023-03-14 11:09:33 +01:00
test-advise.c advice.h: add missing __attribute__((format)) & fix usage 2021-07-13 15:20:20 -07:00
test-bitmap.c t/helper/test-bitmap.c: add 'dump-hashes' mode 2021-09-14 16:34:17 -07:00
test-bloom.c test-tool bloom: fix memory leaks 2022-07-01 13:38:50 -07:00
test-bundle-uri.c test-bundle-uri: drop unused variables 2023-01-06 21:34:49 +09:00
test-cache-tree.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-chmtime.c t/helper/test-chmtime: skip directories on Windows 2022-03-25 16:04:17 -07:00
test-config.c git-compat-util.h: use "UNUSED", not "UNUSED(var)" 2022-09-01 10:49:48 -07:00
test-crontab.c test-crontab: minor memory and error handling fixes 2022-08-30 14:31:37 -07:00
test-csprng.c wrapper: add a helper to generate numbers from a CSPRNG 2022-01-17 14:17:48 -08:00
test-ctype.c test-ctype: test iscntrl, ispunct, isxdigit and isprint 2023-02-13 13:36:05 -08:00
test-date.c date API: add and use a date_mode_release() 2022-02-16 09:40:00 -08:00
test-delta.c test-tool delta: fix a memory leak 2022-07-01 13:38:50 -07:00
test-dir-iterator.c dir-iterator: drop unused `DIR_ITERATOR_FOLLOW_SYMLINKS` 2023-02-16 16:21:56 -08:00
test-drop-caches.c lazyload: use correct calling conventions 2022-01-09 10:34:53 -08:00
test-dump-cache-tree.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-dump-fsmonitor.c
test-dump-split-index.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-dump-untracked-cache.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-env-helper.c env-helper: move this built-in to "test-tool env-helper" 2023-01-14 18:07:11 -08:00
test-example-decorate.c lookup_unknown_object(): take a repository argument 2021-04-13 13:18:46 -07:00
test-fake-ssh.c Merge branch 'ab/various-leak-fixes' 2022-12-14 15:55:46 +09:00
test-fast-rebase.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-fsmonitor-client.c t/helper/fsmonitor-client: create stress test 2022-05-26 15:59:26 -07:00
test-genrandom.c
test-genzeros.c test-genzeros: avoid raw write(2) 2023-02-16 08:30:38 -08:00
test-getcwd.c t0001: fix broken not-quite getcwd(3) test in bed67874e2 2021-07-30 10:18:27 -07:00
test-gvfs-protocol.c t5799: add tests to detect corrupt pack/idx files in prefetch 2023-04-17 11:27:47 -04:00
test-hash-speed.c builtins + test helpers: use return instead of exit() in cmd_* 2021-06-09 09:15:58 +09:00
test-hash.c test-tool test-hash: fix a memory leak 2022-07-01 13:38:49 -07:00
test-hashmap.c Use new HASHMAP_INIT macro to simplify hashmap initialization 2020-11-11 12:55:27 -08:00
test-hexdump.c t/helper/hexdump: add helper to print hexdump of stdin 2022-05-26 15:59:27 -07:00
test-iconv.c test-tool: learn to act as a drop-in replacement for `iconv` 2023-03-13 18:23:45 +01:00
test-index-version.c
test-json-writer.c test-tool json-writer: fix memory leaks 2022-07-01 13:38:50 -07:00
test-lazy-init-name-hash.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-match-trees.c builtins + test helpers: use return instead of exit() in cmd_* 2021-06-09 09:15:58 +09:00
test-mergesort.c test-mergesort: use mem_pool for sort input 2022-08-28 13:10:22 -07:00
test-mktemp.c
test-oid-array.c tests: fix test-oid-array leak, test in SANITIZE=leak 2021-10-07 15:40:15 -07:00
test-oidmap.c
test-oidtree.c tests: fix a memory leak in test-oidtree.c 2021-10-07 15:40:15 -07:00
test-online-cpus.c
test-pack-mtimes.c t/helper: add 'pack-mtimes' test-tool 2022-05-26 15:48:26 -07:00
test-parse-options.c test-parse-options.c: fix style of comparison with zero 2022-09-07 12:06:12 -07:00
test-parse-pathspec-file.c
test-partial-clone.c promisor-remote: teach lazy-fetch in any repo 2021-06-28 09:58:01 -07:00
test-path-utils.c string-list: mark unused callback parameters 2022-10-17 21:24:04 -07:00
test-pcre2-config.c grep/pcre2: better support invalid UTF-8 haystacks 2021-01-24 16:09:17 -08:00
test-pkt-line.c test-lib-functions: use test-tool for [de]packetize() 2021-07-19 11:53:50 -07:00
test-prio-queue.c tests: fix a memory leak in test-prio-queue.c 2021-10-07 15:40:15 -07:00
test-proc-receive.c doc txt & -h consistency: use "<options>", not "<options>..." 2022-10-13 09:32:55 -07:00
test-progress.c progress.c tests: make start/stop commands on stdin 2022-02-03 15:39:55 -08:00
test-reach.c builtins + test helpers: use return instead of exit() in cmd_* 2021-06-09 09:15:58 +09:00
test-read-cache.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-read-graph.c test-read-graph: include extra post-parse info 2022-03-01 12:09:55 -08:00
test-read-midx.c t/helper/test-read-midx.c: free MIDX within read_midx_file() 2021-10-27 16:26:37 -07:00
test-ref-store.c git-compat-util.h: use "UNUSED", not "UNUSED(var)" 2022-09-01 10:49:48 -07:00
test-reftable.c reftable: order unittests by complexity 2022-01-20 11:31:53 -08:00
test-regex.c test-tool regex: call regfree(), fix memory leaks 2022-07-01 13:38:50 -07:00
test-repository.c
test-revision-walking.c revisions API users: add straightforward release_revisions() 2022-04-13 23:56:08 -07:00
test-rot13-filter.c t0021: implementation the rot13-filter.pl script in C 2022-08-14 22:57:12 -07:00
test-run-command.c run-command API: have run_process_parallel() take an "opts" struct 2022-10-12 14:12:41 -07:00
test-scrap-cache-tree.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-serve-v2.c parse-options: PARSE_OPT_KEEP_UNKNOWN only applies to --options 2022-08-19 11:13:14 -07:00
test-sha1.c Makefile & test-tool: replace "DC_SHA1" variable with a "define" 2022-11-07 22:11:51 -05:00
test-sha1.sh
test-sha256.c
test-sigchain.c
test-simple-ipc.c t/helper/simple-ipc: convert test-simple-ipc to use start_bg_command 2021-09-20 08:57:58 -07:00
test-strcmp-offset.c
test-string-list.c
test-submodule-config.c test-tool submodule-config: remove unused "--url" handling 2022-09-02 09:16:23 -07:00
test-submodule-nested-repo-config.c repository: support unabsorbed in repo_submodule_init 2021-09-09 14:09:30 -07:00
test-submodule.c submodule--helper: move "config" to a test-tool 2022-11-08 14:55:30 -05:00
test-subprocess.c run-command API users: use strvec_pushv(), not argv assignment 2021-11-25 22:15:07 -08:00
test-tool-utils.h submodule--helper: move "is-active" to a test-tool 2022-09-02 09:16:23 -07:00
test-tool.c test-tool: learn to act as a drop-in replacement for `iconv` 2023-03-13 18:23:45 +01:00
test-tool.h test-tool: learn to act as a drop-in replacement for `iconv` 2023-03-13 18:23:45 +01:00
test-trace2.c Merge branch 'rs/no-more-run-command-v' 2022-11-08 17:15:12 -05:00
test-urlmatch-normalization.c test-tool urlmatch-normalization: fix a memory leak 2022-07-01 13:38:49 -07:00
test-userdiff.c git-compat-util.h: use "UNUSED", not "UNUSED(var)" 2022-09-01 10:49:48 -07:00
test-wildmatch.c
test-windows-named-pipe.c
test-write-cache.c cache.h & test-tool.h: add & use "USE_THE_INDEX_VARIABLE" 2022-11-21 12:06:15 +09:00
test-xml-encode.c