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
25
third_party/git/t/t5530-upload-pack-error.sh
vendored
25
third_party/git/t/t5530-upload-pack-error.sh
vendored
|
|
@ -14,7 +14,6 @@ corrupt_repo () {
|
|||
}
|
||||
|
||||
test_expect_success 'setup and corrupt repository' '
|
||||
|
||||
echo file >file &&
|
||||
git add file &&
|
||||
git rev-parse :file &&
|
||||
|
|
@ -31,9 +30,10 @@ test_expect_success 'fsck fails' '
|
|||
'
|
||||
|
||||
test_expect_success 'upload-pack fails due to error in pack-objects packing' '
|
||||
|
||||
printf "0032want %s\n00000009done\n0000" \
|
||||
$(git rev-parse HEAD) >input &&
|
||||
head=$(git rev-parse HEAD) &&
|
||||
hexsz=$(test_oid hexsz) &&
|
||||
printf "%04xwant %s\n00000009done\n0000" \
|
||||
$(($hexsz + 10)) $head >input &&
|
||||
test_must_fail git upload-pack . <input >/dev/null 2>output.err &&
|
||||
test_i18ngrep "unable to read" output.err &&
|
||||
test_i18ngrep "pack-objects died" output.err
|
||||
|
|
@ -51,16 +51,17 @@ test_expect_success 'fsck fails' '
|
|||
'
|
||||
test_expect_success 'upload-pack fails due to error in rev-list' '
|
||||
|
||||
printf "0032want %s\n0034shallow %s00000009done\n0000" \
|
||||
$(git rev-parse HEAD) $(git rev-parse HEAD^) >input &&
|
||||
printf "%04xwant %s\n%04xshallow %s00000009done\n0000" \
|
||||
$(($hexsz + 10)) $(git rev-parse HEAD) \
|
||||
$(($hexsz + 12)) $(git rev-parse HEAD^) >input &&
|
||||
test_must_fail git upload-pack . <input >/dev/null 2>output.err &&
|
||||
grep "bad tree object" output.err
|
||||
'
|
||||
|
||||
test_expect_success 'upload-pack fails due to bad want (no object)' '
|
||||
|
||||
printf "0045want %s multi_ack_detailed\n00000009done\n0000" \
|
||||
"deadbeefdeadbeefdeadbeefdeadbeefdeadbeef" >input &&
|
||||
printf "%04xwant %s multi_ack_detailed\n00000009done\n0000" \
|
||||
$(($hexsz + 29)) $(test_oid deadbeef) >input &&
|
||||
test_must_fail git upload-pack . <input >output 2>output.err &&
|
||||
grep "not our ref" output.err &&
|
||||
grep "ERR" output &&
|
||||
|
|
@ -70,8 +71,8 @@ test_expect_success 'upload-pack fails due to bad want (no object)' '
|
|||
test_expect_success 'upload-pack fails due to bad want (not tip)' '
|
||||
|
||||
oid=$(echo an object we have | git hash-object -w --stdin) &&
|
||||
printf "0045want %s multi_ack_detailed\n00000009done\n0000" \
|
||||
"$oid" >input &&
|
||||
printf "%04xwant %s multi_ack_detailed\n00000009done\n0000" \
|
||||
$(($hexsz + 29)) "$oid" >input &&
|
||||
test_must_fail git upload-pack . <input >output 2>output.err &&
|
||||
grep "not our ref" output.err &&
|
||||
grep "ERR" output &&
|
||||
|
|
@ -80,8 +81,8 @@ test_expect_success 'upload-pack fails due to bad want (not tip)' '
|
|||
|
||||
test_expect_success 'upload-pack fails due to error in pack-objects enumeration' '
|
||||
|
||||
printf "0032want %s\n00000009done\n0000" \
|
||||
$(git rev-parse HEAD) >input &&
|
||||
printf "%04xwant %s\n00000009done\n0000" \
|
||||
$((hexsz + 10)) $(git rev-parse HEAD) >input &&
|
||||
test_must_fail git upload-pack . <input >/dev/null 2>output.err &&
|
||||
grep "bad tree object" output.err &&
|
||||
grep "pack-objects died" output.err
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue