merge(3p/git): Merge git subtree at v2.29.2
This also bumps the stable nixpkgs to 20.09 as of 2020-11-21, because there is some breakage in the git build related to the netrc credentials helper which someone has taken care of in nixpkgs. The stable channel is not used for anything other than git, so this should be fine. Change-Id: I3575a19dab09e1e9556cf8231d717de9890484fb
This commit is contained in:
parent
082c006c04
commit
f4609b896f
1485 changed files with 241535 additions and 109418 deletions
33
third_party/git/t/t6500-gc.sh
vendored
33
third_party/git/t/t6500-gc.sh
vendored
|
|
@ -10,7 +10,24 @@ test_expect_success 'setup' '
|
|||
# do not let the amount of physical memory affects gc
|
||||
# behavior, make sure we always pack everything to one pack by
|
||||
# default
|
||||
git config gc.bigPackThreshold 2g
|
||||
git config gc.bigPackThreshold 2g &&
|
||||
|
||||
# These are simply values which, when hashed as a blob with a newline,
|
||||
# produce a hash where the first byte is 0x17 in their respective
|
||||
# algorithms.
|
||||
test_oid_cache <<-EOF
|
||||
obj1 sha1:263
|
||||
obj1 sha256:34
|
||||
|
||||
obj2 sha1:410
|
||||
obj2 sha256:174
|
||||
|
||||
obj3 sha1:523
|
||||
obj3 sha256:313
|
||||
|
||||
obj4 sha1:790
|
||||
obj4 sha256:481
|
||||
EOF
|
||||
'
|
||||
|
||||
test_expect_success 'gc empty repository' '
|
||||
|
|
@ -85,13 +102,13 @@ test_expect_success 'auto gc with too many loose objects does not attempt to cre
|
|||
# We need to create two object whose sha1s start with 17
|
||||
# since this is what git gc counts. As it happens, these
|
||||
# two blobs will do so.
|
||||
test_commit 263 &&
|
||||
test_commit 410 &&
|
||||
test_commit "$(test_oid obj1)" &&
|
||||
test_commit "$(test_oid obj2)" &&
|
||||
# Our first gc will create a pack; our second will create a second pack
|
||||
git gc --auto &&
|
||||
ls .git/objects/pack | sort >existing_packs &&
|
||||
test_commit 523 &&
|
||||
test_commit 790 &&
|
||||
test_commit "$(test_oid obj3)" &&
|
||||
test_commit "$(test_oid obj4)" &&
|
||||
|
||||
git gc --auto 2>err &&
|
||||
test_i18ngrep ! "^warning:" err &&
|
||||
|
|
@ -103,14 +120,14 @@ test_expect_success 'auto gc with too many loose objects does not attempt to cre
|
|||
'
|
||||
|
||||
test_expect_success 'gc --no-quiet' '
|
||||
git -c gc.writeCommitGraph=true gc --no-quiet >stdout 2>stderr &&
|
||||
GIT_PROGRESS_DELAY=0 git -c gc.writeCommitGraph=true gc --no-quiet >stdout 2>stderr &&
|
||||
test_must_be_empty stdout &&
|
||||
test_line_count = 1 stderr &&
|
||||
test_i18ngrep "Computing commit graph generation numbers" stderr
|
||||
'
|
||||
|
||||
test_expect_success TTY 'with TTY: gc --no-quiet' '
|
||||
test_terminal git -c gc.writeCommitGraph=true gc --no-quiet >stdout 2>stderr &&
|
||||
test_terminal env GIT_PROGRESS_DELAY=0 \
|
||||
git -c gc.writeCommitGraph=true gc --no-quiet >stdout 2>stderr &&
|
||||
test_must_be_empty stdout &&
|
||||
test_i18ngrep "Enumerating objects" stderr &&
|
||||
test_i18ngrep "Computing commit graph generation numbers" stderr
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue