Skip to content

Commit 87c8020

Browse files
committed
t2000: cleanup unused debug code and variables
Remove the show_files function which is no longer used after removing test_debug calls, and remove an unused tree3 variable assignment in the second test scenario. These cleanups address feedback from Junio C Hamano regarding the modernization of this test script. Signed-off-by: Zakariyah Ali <zakariyahali100@gmail.com>
1 parent 4da2092 commit 87c8020

1 file changed

Lines changed: 0 additions & 12 deletions

File tree

t/t2000-conflict-when-checking-files-out.sh

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,6 @@ test_description='git conflicts when checking files out test.'
2323

2424
. ./test-lib.sh
2525

26-
show_files() {
27-
# show filesystem files, just [-dl] for type and name
28-
find path? -ls |
29-
sed -e 's/^[0-9]* * [0-9]* * \([-bcdl]\)[^ ]* *[0-9]* *[^ ]* *[^ ]* *[0-9]* [A-Z][a-z][a-z] [0-9][0-9] [^ ]* /fs: \1 /'
30-
# what's in the cache, just mode and name
31-
git ls-files --stage |
32-
sed -e 's/^\([0-9]*\) [0-9a-f]* [0-3] /ca: \1 /'
33-
# what's in the tree, just mode and name.
34-
git ls-tree -r "$1" |
35-
sed -e 's/^\([0-9]*\) [^ ]* [0-9a-f]* /tr: \1 /'
36-
}
3726

3827
test_expect_success 'prepare files path0 and path1/file1' '
3928
date >path0 &&
@@ -96,7 +85,6 @@ test_expect_success 'checkout-index -f resolves symlink conflict on leading path
9685
git read-tree -m $tree1 &&
9786
git checkout-index -f -a &&
9887
test_ln_s_add path2 path3 &&
99-
tree3=$(git write-tree) &&
10088
git read-tree $tree2 &&
10189
git checkout-index -f -a &&
10290
test_path_is_dir_not_symlink path2 &&

0 commit comments

Comments
 (0)