]> git.ipfire.org Git - thirdparty/git.git/commitdiff
leak tests: run various built-in tests in t00*.sh SANITIZE=leak
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>
Tue, 12 Oct 2021 13:56:37 +0000 (15:56 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 13 Oct 2021 01:23:24 +0000 (18:23 -0700)
Mark various existing tests in t00*.sh that invoke git built-ins with
TEST_PASSES_SANITIZE_LEAK=true 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>
13 files changed:
t/t0001-init.sh
t/t0002-gitfile.sh
t/t0003-attributes.sh
t/t0005-signals.sh
t/t0007-git-var.sh
t/t0008-ignores.sh
t/t0010-racy-git.sh
t/t0022-crlf-rename.sh
t/t0024-crlf-archive.sh
t/t0025-crlf-renormalize.sh
t/t0026-eol-config.sh
t/t0029-core-unsetenvvars.sh
t/t0055-beyond-symlinks.sh

index df544bb321fee8eb4537d32dbea11de82cb65b28..7603ad2f82b28264ce19ae77d6bbc250fb9a94fa 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='git init'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 check_config () {
index 8440e6add1237e7d08f6b0010950b0d96b9e920d..76052cb5620bebd4965370077a303d3f633154fc 100755 (executable)
@@ -7,6 +7,7 @@ Verify that plumbing commands work when .git is a file
 GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
 export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 objpath() {
index 1e4c672b84aa366de04969b3c3f073c1f02ce92f..b9ed612af13262c0467aed2be927bd4704a221e4 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description=gitattributes
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 attr_check_basic () {
index 4c214bd11c48859f0c4e64dbbe2d783e744eb1d1..a5ec6a0315ca09893e5c2b7403e91f2a0be0109c 100755 (executable)
@@ -1,6 +1,8 @@
 #!/bin/sh
 
 test_description='signals work as we expect'
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 cat >expect <<EOF
index 88b9ae81588d1cd8581c29faf67ee8fe4a4e9a6d..53af92d571a92b2dccd37300e71ea030dde947c8 100755 (executable)
@@ -1,6 +1,8 @@
 #!/bin/sh
 
 test_description='basic sanity checks for git var'
+
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success 'get GIT_AUTHOR_IDENT' '
index a594b4aa7d045cb0c03c0eea8591912ee052dca8..532637de882c200b71b538ee56b839856d575f22 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description=check-ignore
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 init_vars () {
index 5657c5a87b6e253b8c8ca7d18dfa7535c295dc83..837c8b7228b98e8e7b3dbfecd5046673554ef464 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='racy GIT'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 # This test can give false success if your machine is sufficiently
index 7af3fbcc7b9e5e61e41205accaa6d81e85cae6cf..c1a331e9e939fa975ba038934e885bb2fe93b63c 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='ignore CR in CRLF sequence while computing similiarity'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index 4e9fa3cd68426942357d8f89ffa97ed3099e1084..a34de5642073d1323b37b7c82f56edfe798fcfdd 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='respect crlf in git archive'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index e13363ade5cf500e6f57677eb961c5ca01197a12..81447978b7f66a7a2169341f0b6da649e106e8bd 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='CRLF renormalization'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success setup '
index c5203e232c8b6e480e2c3a16dca78d625f364aac..cdcafcdff724e2c13ee056fb59e915a5371ec13c 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='CRLF conversion'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 has_cr() {
index 24ce46a6ea15cfcbf99d4affac625c61b2dd7286..b138e1d9cbcd9c459e8e1ce3849a199cb177f57b 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='test the Windows-only core.unsetenvvars setting'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 if ! test_have_prereq MINGW
index 0c6ff567a1d47f52492dd89bd098b25bae737bad..6bada3702257649551558884237f71bea3fdadc2 100755 (executable)
@@ -2,6 +2,7 @@
 
 test_description='update-index and add refuse to add beyond symlinks'
 
+TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 test_expect_success SYMLINKS setup '