]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test-network: read default values from environment variables
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 5 Nov 2025 15:21:22 +0000 (00:21 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 5 Nov 2025 15:22:17 +0000 (00:22 +0900)
Nowadays, the test script is run as a service, and no argument about
sanitizers are passed. Let's read them from the environment variables.

test/test-network/systemd-networkd-tests.py

index b650b34f98727bf30478d332244f46fa4e3d0834..6802646728c9e5bbca4ecd43ef1295cee8e4f627 100755 (executable)
@@ -81,10 +81,10 @@ valgrind_cmd = ''
 enable_debug = True
 env = {}
 wait_online_env = {}
-asan_options = None
-lsan_options = None
-ubsan_options = None
-with_coverage = False
+asan_options = os.getenv('ASAN_OPTIONS')
+lsan_options = os.getenv('LSAN_OPTIONS')
+ubsan_options = os.getenv('UBSAN_OPTIONS')
+with_coverage = os.getenv('COVERAGE_BUILD_DIR') != None
 show_journal = True # When true, show journal on stopping networkd.
 
 active_units = []