Skip to content

Commit 5a4f838

Browse files
committed
Merge branch 'ab/mark-leak-free-tests'
Bunch of tests are marked as "passing leak check". * ab/mark-leak-free-tests: leak tests: mark some misc tests as passing with SANITIZE=leak leak tests: mark various "generic" tests as passing with SANITIZE=leak leak tests: mark some read-tree tests as passing with SANITIZE=leak leak tests: mark some ls-files tests as passing with SANITIZE=leak leak tests: mark all checkout-index tests as passing with SANITIZE=leak leak tests: mark all trace2 tests as passing with SANITIZE=leak leak tests: mark all ls-tree tests as passing with SANITIZE=leak leak tests: run various "test-tool" tests in t00*.sh SANITIZE=leak leak tests: run various built-in tests in t00*.sh SANITIZE=leak
2 parents 65ca324 + 7ff2478 commit 5a4f838

File tree

66 files changed

+86
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+86
-0
lines changed

t/t0001-init.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='git init'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
check_config () {

t/t0002-gitfile.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Verify that plumbing commands work when .git is a file
77
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
88
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
99

10+
TEST_PASSES_SANITIZE_LEAK=true
1011
. ./test-lib.sh
1112

1213
objpath() {

t/t0003-attributes.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description=gitattributes
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
attr_check_basic () {

t/t0005-signals.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='signals work as we expect'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
cat >expect <<EOF

t/t0007-git-var.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='basic sanity checks for git var'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
test_expect_success 'get GIT_AUTHOR_IDENT' '

t/t0008-ignores.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description=check-ignore
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
init_vars () {

t/t0010-racy-git.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='racy GIT'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
# This test can give false success if your machine is sufficiently

t/t0013-sha1dc.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='test sha1 collision detection'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57
TEST_DATA="$TEST_DIRECTORY/t0013"
68

t/t0022-crlf-rename.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='ignore CR in CRLF sequence while computing similiarity'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test_expect_success setup '

t/t0024-crlf-archive.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='respect crlf in git archive'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test_expect_success setup '

t/t0025-crlf-renormalize.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='CRLF renormalization'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test_expect_success setup '

t/t0026-eol-config.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='CRLF conversion'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
has_cr() {

t/t0029-core-unsetenvvars.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='test the Windows-only core.unsetenvvars setting'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
if ! test_have_prereq MINGW

t/t0052-simple-ipc.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='simple command server'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test-tool simple-ipc SUPPORTS_SIMPLE_IPC || {

t/t0055-beyond-symlinks.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='update-index and add refuse to add beyond symlinks'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test_expect_success SYMLINKS setup '

t/t0061-run-command.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55

66
test_description='Test run command'
77

8+
TEST_PASSES_SANITIZE_LEAK=true
89
. ./test-lib.sh
910

1011
cat >hello-script <<-EOF

t/t0065-strcmp-offset.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='Test strcmp_offset functionality'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
while read s1 s2 expect

t/t0066-dir-iterator.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='Test the dir-iterator functionality'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test_expect_success 'setup' '

t/t0067-parse_pathspec_file.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='Test parse_pathspec_file()'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test_expect_success 'one item from stdin' '

t/t0210-trace2-normal.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='test trace2 facility (normal target)'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
# Turn off any inherited trace2 settings for this test.

t/t0211-trace2-perf.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='test trace2 facility (perf target)'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
# Turn off any inherited trace2 settings for this test.

t/t0212-trace2-event.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='test trace2 facility'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
# Turn off any inherited trace2 settings for this test.

t/t1000-read-tree-m-3way.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ In addition:
7171
DF: a special case, where A makes a directory and B makes a file.
7272
7373
'
74+
75+
TEST_PASSES_SANITIZE_LEAK=true
7476
. ./test-lib.sh
7577
. "$TEST_DIRECTORY"/lib-read-tree.sh
7678
. "$TEST_DIRECTORY"/lib-read-tree-m-3way.sh

t/t1003-read-tree-prefix.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
test_description='git read-tree --prefix test.
77
'
88

9+
TEST_PASSES_SANITIZE_LEAK=true
910
. ./test-lib.sh
1011

1112
test_expect_success setup '

t/t1009-read-tree-new-index.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ test_description='test read-tree into a fresh index file'
55
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
66
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
77

8+
TEST_PASSES_SANITIZE_LEAK=true
89
. ./test-lib.sh
910

1011
test_expect_success setup '

t/t1010-mktree.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='git mktree'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
test_expect_success setup '

t/t1012-read-tree-df.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='read-tree D/F conflict corner cases'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67
. "$TEST_DIRECTORY"/lib-read-tree.sh
78

t/t1014-read-tree-confusing.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='check that read-tree rejects confusing paths'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
test_expect_success 'create base tree' '

t/t1100-commit-tree-options.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ Also make sure that command line parser understands the normal
1212
"flags first and then non flag arguments" command line.
1313
'
1414

15+
TEST_PASSES_SANITIZE_LEAK=true
1516
. ./test-lib.sh
1617

1718
cat >expected <<EOF

t/t1430-bad-ref-name.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ test_description='Test handling of ref names that check-ref-format rejects'
44
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
55
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
66

7+
TEST_PASSES_SANITIZE_LEAK=true
78
. ./test-lib.sh
89

910
test_expect_success setup '

t/t1504-ceiling-dirs.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='test GIT_CEILING_DIRECTORIES'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
test_prefix() {

t/t1510-repo-setup.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ A few rules for repo setup:
4343
# This test heavily relies on the standard error of nested function calls.
4444
test_untraceable=UnfortunatelyYes
4545

46+
TEST_PASSES_SANITIZE_LEAK=true
4647
. ./test-lib.sh
4748

4849
here=$(pwd)

t/t2002-checkout-cache-u.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ test_description='git checkout-index -u test.
88
With -u flag, git checkout-index internally runs the equivalent of
99
git update-index --refresh on the checked out entry.'
1010

11+
TEST_PASSES_SANITIZE_LEAK=true
1112
. ./test-lib.sh
1213

1314
test_expect_success \

t/t2003-checkout-cache-mkdir.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ also verifies that such leading path may contain symlinks, unlike
1010
the GIT controlled paths.
1111
'
1212

13+
TEST_PASSES_SANITIZE_LEAK=true
1314
. ./test-lib.sh
1415

1516
test_expect_success 'setup' '

t/t2004-checkout-cache-temp.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ test_description='git checkout-index --temp test.
88
With --temp flag, git checkout-index writes to temporary merge files
99
rather than the tracked path.'
1010

11+
TEST_PASSES_SANITIZE_LEAK=true
1112
. ./test-lib.sh
1213

1314
test_expect_success 'setup' '

t/t2005-checkout-index-symlinks.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ test_description='git checkout-index on filesystem w/o symlinks test.
88
This tests that git checkout-index creates a symbolic link as a plain
99
file if core.symlinks is false.'
1010

11+
TEST_PASSES_SANITIZE_LEAK=true
1112
. ./test-lib.sh
1213

1314
test_expect_success \

t/t2050-git-dir-relative.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ into the subdir while keeping the worktree location,
1212
and tries commits from the top and the subdir, checking
1313
that the commit-hook still gets called.'
1414

15+
TEST_PASSES_SANITIZE_LEAK=true
1516
. ./test-lib.sh
1617

1718
COMMIT_FILE="$(pwd)/output"

t/t2081-parallel-checkout-collisions.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ The tests in this file exercise parallel checkout's collision detection code in
1111
both these mechanics.
1212
"
1313

14+
TEST_PASSES_SANITIZE_LEAK=true
1415
. ./test-lib.sh
1516
. "$TEST_DIRECTORY/lib-parallel-checkout.sh"
1617

t/t2300-cd-to-toplevel.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='cd_to_toplevel'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
EXEC_PATH="$(git --exec-path)"

t/t3000-ls-files-others.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ filesystem.
1515
path3/file3 - a file in a directory
1616
path4 - an empty directory
1717
'
18+
19+
TEST_PASSES_SANITIZE_LEAK=true
1820
. ./test-lib.sh
1921

2022
test_expect_success 'setup ' '

t/t3002-ls-files-dashpath.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ filesystem.
1212
-foo - a file with a funny name.
1313
-- - another file with a funny name.
1414
'
15+
16+
TEST_PASSES_SANITIZE_LEAK=true
1517
. ./test-lib.sh
1618

1719
test_expect_success \

t/t3003-ls-files-exclude.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='ls-files --exclude does not affect index files'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
test_expect_success 'create repo with file' '

t/t3004-ls-files-basic.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ This test runs git ls-files with various unusual or malformed
66
command-line arguments.
77
'
88

9+
TEST_PASSES_SANITIZE_LEAK=true
910
. ./test-lib.sh
1011

1112
test_expect_success 'ls-files in empty repository' '

t/t3006-ls-files-long.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/bin/sh
22

33
test_description='overly long paths'
4+
5+
TEST_PASSES_SANITIZE_LEAK=true
46
. ./test-lib.sh
57

68
test_expect_success setup '

t/t3008-ls-files-lazy-init-name-hash.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='Test the lazy init name hash with various folder structures'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
if test 1 -eq $(test-tool online-cpus)

t/t3070-wildmatch.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
test_description='wildmatch tests'
44

5+
TEST_PASSES_SANITIZE_LEAK=true
56
. ./test-lib.sh
67

78
# Disable expensive chain-lint tests; all of the tests in this script

t/t3100-ls-tree-restrict.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ This test runs git ls-tree with the following in a tree.
1616
The new path restriction code should do the right thing for path2 and
1717
path2/baz. Also path0/ should snow nothing.
1818
'
19+
20+
TEST_PASSES_SANITIZE_LEAK=true
1921
. ./test-lib.sh
2022

2123
test_expect_success \

t/t3101-ls-tree-dirname.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ This test runs git ls-tree with the following in a tree.
1919
Test the handling of multiple directories which have matching file
2020
entries. Also test odd filename and missing entries handling.
2121
'
22+
23+
TEST_PASSES_SANITIZE_LEAK=true
2224
. ./test-lib.sh
2325

2426
test_expect_success 'setup' '

0 commit comments

Comments
 (0)