]> git.ipfire.org Git - thirdparty/git.git/commitdiff
leak tests: mark some apply tests as passing with SANITIZE=leak
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>
Sat, 30 Oct 2021 22:24:18 +0000 (00:24 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 1 Nov 2021 18:23:08 +0000 (11:23 -0700)
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>
22 files changed:
t/t4100-apply-stat.sh
t/t4101-apply-nonl.sh
t/t4102-apply-rename.sh
t/t4105-apply-fuzz.sh
t/t4106-apply-stdin.sh
t/t4109-apply-multifrag.sh
t/t4110-apply-scan.sh
t/t4112-apply-renames.sh
t/t4116-apply-reverse.sh
t/t4118-apply-empty-context.sh
t/t4119-apply-config.sh
t/t4123-apply-shrink.sh
t/t4126-apply-empty.sh
t/t4127-apply-same-fn.sh
t/t4128-apply-root.sh
t/t4129-apply-samemode.sh
t/t4130-apply-criss-cross-rename.sh
t/t4132-apply-removal.sh
t/t4133-apply-filenames.sh
t/t4134-apply-submodule.sh
t/t4136-apply-check.sh
t/t4139-apply-escape.sh

index 9b433de83630774206fb89dfae1a4396264390cc..d503547732c54d8f952027580dc21a6b65729cdb 100755 (executable)
@@ -6,6 +6,8 @@
 test_description='git apply --stat --summary test, with --recount
 
 '
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 UNC='s/^\(@@ -[1-9][0-9]*\),[0-9]* \(+[1-9][0-9]*\),[0-9]* @@/\1,999 \2,999 @@/'
index e3443d004d026c86fd783cb8e6e3d03f22676778..b1169193ef5d53e06302b01b9a54ad7ed165232c 100755 (executable)
@@ -6,6 +6,8 @@
 test_description='git apply should handle files with incomplete lines.
 
 '
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 # setup
index fae305979a88614bdf33963936d3fce32df83b8c..d1e06fc1ac41354d9a50d6db76663f0b9ff3e698 100755 (executable)
@@ -6,6 +6,8 @@
 test_description='git apply handling copy/rename patch.
 
 '
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 # setup
index 3266e394003958b62509b7bfe6652abd03fdfcb7..76e2c01b0f5a083f605e8493aaa1068f73b30023 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='apply with fuzz and offset'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 dotest () {
index 72467a1e8ee28c4ac2a3d532bd65b9b5503cff06..a57a318699e8989e29e07e4f7559a3656ab42523 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='git apply --numstat - <patch'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index ac58083fe224100987800e9b5ee3e388d9b4d97c..4dc6d8e7d3c8bb834fda0e777e3083283df00033 100755 (executable)
@@ -6,6 +6,8 @@
 
 test_description='git apply test patches with multiple fragments.'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 cp "$TEST_DIRECTORY/t4109/patch1.patch" .
index 09f58112e0229a41ea2a5d2ea6e8c23d2523298d..266302a1829da4a0e289987c7d572a0fb9cdbc73 100755 (executable)
@@ -7,6 +7,8 @@
 test_description='git apply test for patches which require scanning forwards and backwards.
 
 '
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success 'git apply scan' '
index f9ad183758c28ff648890d1bd4bbd599562cd795..d53aa4222ea3c1405247e07d62fc8efed83daa5d 100755 (executable)
@@ -7,6 +7,8 @@ test_description='git apply should not get confused with rename/copy.
 
 '
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 # setup
index b99e65c086391276aeb809b8651507026509e19a..f3b635475a446597ebb6cd15336c91b6d12a49dc 100755 (executable)
@@ -7,6 +7,8 @@ test_description='git apply in reverse
 
 '
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index 65f2e4c3efb9ae5b5459e15df337e07201d78c38..5fc6d3e4e7c01f37572e52dd7f55fce6d58fb622 100755 (executable)
@@ -7,6 +7,8 @@ test_description='git apply with new style GNU diff with empty context
 
 '
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index a9a05838119c85bc017f1404b134d393029843b2..208c961d376b28035e3e7c9563199f9c5867cf11 100755 (executable)
@@ -7,6 +7,8 @@ test_description='git apply --whitespace=strip and configuration file.
 
 '
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index 984157f03b9744aa491c888fab9e6aef95dfdc6b..ef57cd3aebb67d88861b8e02a63baa7437076053 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='apply a patch that is larger than the preimage'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 cat >F  <<\EOF
index ceb6a79fe0c8ca5b26a9e148215556f2aa344eb9..a361e79a815690469585428d70a5cda2836dfe4a 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='apply empty'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index 305b7e649eb7a123556d89deae0c34ec91265905..c27e9aec570401ab76c69aed17083b07558889de 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='apply same filename'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 modify () {
index 6cc741a634b0352c54fe8e5f61f1e99543909b8c..cb3181e8b71a8e25586467c20086063b33ec36d0 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='apply same filename'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success 'setup' '
index 576632f8681e76032c0f87ac0b65833314058035..a1c7686519ebb1284d818fd3f5615853082abc01 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='applying patch with mode bits'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index f8a313bcb98c6e2b98982295773bdc8ac7e13256..f3ea63274258c664fd612dc314e205b9804cc13c 100755 (executable)
@@ -1,6 +1,8 @@
 #!/bin/sh
 
 test_description='git apply handling criss-cross rename patch.'
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 create_file() {
index fec1d6fa51faec22da97eb62165c588e2ba9f655..c1e3049c041b849f4b8c1d1322a44ea77fd96845 100755 (executable)
@@ -4,6 +4,8 @@
 
 test_description='git-apply notices removal patches generated by GNU diff'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index c5ed3b17c4a1196e154affc346b5fd3d4e0a7abf..35f1060bc8b47f3f4de129621392c0b23b8f4c18 100755 (executable)
@@ -5,6 +5,8 @@
 
 test_description='git apply filename consistency check'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index d1c16ba33c114477616d82d8e5d9fcbf53ed53ef..aceb4c42b0ffc7e20a0a9cc07843a953e703b269 100755 (executable)
@@ -5,6 +5,8 @@
 
 test_description='git apply submodule tests'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index 4c3f264a633b770445e116edfac83872b47916bf..dfec1c5f0f63fca3b0f0f47d2296be93c0e4f1ed 100755 (executable)
@@ -2,6 +2,8 @@
 
 test_description='git apply should exit non-zero with unrecognized input.'
 
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success 'setup' '
index 45b5660a47d88f736aa777641084d13b45852969..e5c7439df13389a3caa9f3f76f70e31fea96c90b 100755 (executable)
@@ -1,6 +1,8 @@
 #!/bin/sh
 
 test_description='paths written by git-apply cannot escape the working tree'
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 # tests will try to write to ../foo, and we do not