Skip to content

Commit effc81a

Browse files
committed
t5538: confirm deltas in shallow pushes
It can be notoriously difficult to detect if delta bases are being computed properly during 'git push'. Construct an example where it will make a kilobyte worth of difference when a delta base is not found. We can then use the progress indicators to distinguish between bytes and KiB depending on whether the delta base is found and used. Signed-off-by: Derrick Stolee <[email protected]>
1 parent 7e6eac0 commit effc81a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

t/t5538-push-shallow.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,8 @@ test_expect_success 'push new commit from shallow clone has good deltas' '
150150
GIT_TRACE2_PERF="$(pwd)/trace.txt" \
151151
GIT_PROGRESS_DELAY=0 git -C deltas push --progress origin deltas 2>err &&
152152
153+
test_grep "Enumerating objects: 5, done" err &&
154+
153155
# If the delta base is found, then this message uses "bytes".
154156
# If the delta base is not found, then this message uses "KiB".
155157
test_grep "Writing objects: .* bytes" err

0 commit comments

Comments
 (0)