File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -115,4 +115,25 @@ test_expect_success 'push with transfer.fsckobjects' '
115
115
test_cmp exp act
116
116
'
117
117
118
+ cat > bogus-commit << \EOF
119
+ tree 4b825dc642cb6eb9a060e54bf8d69288fbee4904
120
+ author Bugs Bunny 1234567890 +0000
121
+ committer Bugs Bunny <[email protected] > 1234567890 +0000
122
+
123
+ This commit object intentionally broken
124
+ EOF
125
+
126
+ test_expect_success ' push with receive.fsck.missingEmail=warn' '
127
+ commit="$(git hash-object -t commit -w --stdin <bogus-commit)" &&
128
+ git push . $commit:refs/heads/bogus &&
129
+ rm -rf dst &&
130
+ git init dst &&
131
+ git --git-dir=dst/.git config receive.fsckobjects true &&
132
+ test_must_fail git push --porcelain dst bogus &&
133
+ git --git-dir=dst/.git config \
134
+ receive.fsck.missingEmail warn &&
135
+ git push --porcelain dst bogus >act 2>&1 &&
136
+ grep "missingEmail" act
137
+ '
138
+
118
139
test_done
You can’t perform that action at this time.
0 commit comments