Skip to content

Commit 147c3f6

Browse files
ttaylorrgitster
authored andcommitted
t/t5313-pack-bounds-checks.sh: prepare for sub-directories
Prepare for sub-directories to appear in $GIT_DIR/objects/pack by adjusting the copy, remove, and chmod invocations to perform their behavior recursively. This prepares us for the new $GIT_DIR/objects/pack/multi-pack-index.d directory which will be added in a following commit. Signed-off-by: Taylor Blau <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 9552c35 commit 147c3f6

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

t/t5313-pack-bounds-checks.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ TEST_PASSES_SANITIZE_LEAK=true
77

88
clear_base () {
99
test_when_finished 'restore_base' &&
10-
rm -f $base
10+
rm -r -f $base
1111
}
1212

1313
restore_base () {
14-
cp base-backup/* .git/objects/pack/
14+
cp -r base-backup/* .git/objects/pack/
1515
}
1616

1717
do_pack () {
@@ -64,9 +64,9 @@ test_expect_success 'set up base packfile and variables' '
6464
git commit -m base &&
6565
git repack -ad &&
6666
base=$(echo .git/objects/pack/*) &&
67-
chmod +w $base &&
67+
chmod -R +w $base &&
6868
mkdir base-backup &&
69-
cp $base base-backup/ &&
69+
cp -r $base base-backup/ &&
7070
object=$(git rev-parse HEAD:file)
7171
'
7272

0 commit comments

Comments
 (0)