leak tests: mark some apply tests as passing with SANITIZE=leak
Mark some tests that match "*apply*" as passing when git is compiled with SANITIZE=leak. They'll now be listed as running under the "GIT_TEST_PASSING_SANITIZE_LEAK=true" test mode (the "linux-leaks" CI target). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Ævar Arnfjörð Bjarmason committed
Oct 31, 2021 at 00:24 UTC
f54f48fc074510a93a18d889a9c3f5dc108efb47
22 files changed
+44
t/t4100-apply-stat.sh
+2
@@ -6,6 +6,8 @@
6
test_description='git apply --stat --summary test, with --recount
7
8
'
9
+
10
+TEST_PASSES_SANITIZE_LEAK=true
11
. ./test-lib.sh
12
13
UNC='s/^\(@@ -[1-9][0-9]*\),[0-9]* \(+[1-9][0-9]*\),[0-9]* @@/\1,999 \2,999 @@/'
t/t4101-apply-nonl.sh
+2
@@ -6,6 +6,8 @@
6
test_description='git apply should handle files with incomplete lines.
7
8
'
9
+
10
+TEST_PASSES_SANITIZE_LEAK=true
11
. ./test-lib.sh
12
13
# setup
t/t4102-apply-rename.sh
+2
@@ -6,6 +6,8 @@
6
test_description='git apply handling copy/rename patch.
7
8
'
9
+
10
+TEST_PASSES_SANITIZE_LEAK=true
11
. ./test-lib.sh
12
13
# setup
t/t4105-apply-fuzz.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='apply with fuzz and offset'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
dotest () {
t/t4106-apply-stdin.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='git apply --numstat - <patch'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
test_expect_success setup '
t/t4109-apply-multifrag.sh
+2
@@ -6,6 +6,8 @@
6
7
test_description='git apply test patches with multiple fragments.'
8
9
+
10
+TEST_PASSES_SANITIZE_LEAK=true
11
. ./test-lib.sh
12
13
cp "$TEST_DIRECTORY/t4109/patch1.patch" .
t/t4110-apply-scan.sh
+2
@@ -7,6 +7,8 @@
7
test_description='git apply test for patches which require scanning forwards and backwards.
8
9
'
10
+
11
+TEST_PASSES_SANITIZE_LEAK=true
12
. ./test-lib.sh
13
14
test_expect_success 'git apply scan' '
t/t4112-apply-renames.sh
+2
@@ -7,6 +7,8 @@ test_description='git apply should not get confused with rename/copy.
7
8
'
9
10
+
11
+TEST_PASSES_SANITIZE_LEAK=true
12
. ./test-lib.sh
13
14
# setup
t/t4116-apply-reverse.sh
+2
@@ -7,6 +7,8 @@ test_description='git apply in reverse
7
8
'
9
10
+
11
+TEST_PASSES_SANITIZE_LEAK=true
12
. ./test-lib.sh
13
14
test_expect_success setup '
t/t4118-apply-empty-context.sh
+2
@@ -7,6 +7,8 @@ test_description='git apply with new style GNU diff with empty context
7
8
'
9
10
+
11
+TEST_PASSES_SANITIZE_LEAK=true
12
. ./test-lib.sh
13
14
test_expect_success setup '
t/t4119-apply-config.sh
+2
@@ -7,6 +7,8 @@ test_description='git apply --whitespace=strip and configuration file.
7
8
'
9
10
+
11
+TEST_PASSES_SANITIZE_LEAK=true
12
. ./test-lib.sh
13
14
test_expect_success setup '
t/t4123-apply-shrink.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='apply a patch that is larger than the preimage'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
cat >F <<\EOF
t/t4126-apply-empty.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='apply empty'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
test_expect_success setup '
t/t4127-apply-same-fn.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='apply same filename'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
modify () {
t/t4128-apply-root.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='apply same filename'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
test_expect_success 'setup' '
t/t4129-apply-samemode.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='applying patch with mode bits'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
test_expect_success setup '
t/t4130-apply-criss-cross-rename.sh
+2
@@ -1,6 +1,8 @@
1
#!/bin/sh
2
3
test_description='git apply handling criss-cross rename patch.'
4
+
5
+TEST_PASSES_SANITIZE_LEAK=true
6
. ./test-lib.sh
7
8
create_file() {
t/t4132-apply-removal.sh
+2
@@ -4,6 +4,8 @@
4
5
test_description='git-apply notices removal patches generated by GNU diff'
6
7
+
8
+TEST_PASSES_SANITIZE_LEAK=true
9
. ./test-lib.sh
10
11
test_expect_success setup '
t/t4133-apply-filenames.sh
+2
@@ -5,6 +5,8 @@
5
6
test_description='git apply filename consistency check'
7
8
+
9
+TEST_PASSES_SANITIZE_LEAK=true
10
. ./test-lib.sh
11
12
test_expect_success setup '
t/t4134-apply-submodule.sh
+2
@@ -5,6 +5,8 @@
5
6
test_description='git apply submodule tests'
7
8
+
9
+TEST_PASSES_SANITIZE_LEAK=true
10
. ./test-lib.sh
11
12
test_expect_success setup '
t/t4136-apply-check.sh
+2
@@ -2,6 +2,8 @@
2
3
test_description='git apply should exit non-zero with unrecognized input.'
4
5
+
6
+TEST_PASSES_SANITIZE_LEAK=true
7
. ./test-lib.sh
8
9
test_expect_success 'setup' '
t/t4139-apply-escape.sh
+2
@@ -1,6 +1,8 @@
1
#!/bin/sh
2
3
test_description='paths written by git-apply cannot escape the working tree'
4
+
5
+TEST_PASSES_SANITIZE_LEAK=true
6
. ./test-lib.sh
7
8
# tests will try to write to ../foo, and we do not