From: Otto Moerbeek Date: Mon, 22 Nov 2021 14:28:42 +0000 (+0100) Subject: Cleanup libfaketime handling in rec regression tests X-Git-Tag: dnsdist-1.7.0-beta2~11^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F11019%2Fhead;p=thirdparty%2Fpdns.git Cleanup libfaketime handling in rec regression tests - Use the MT variant for libfaketime, we are MT after all - It is only needed for auth and LD_PRELOAD is set by the tests where it matters - It interacts badly with libfstrm and tsan in the recursor - No more separate run of the dnstap test is needed --- diff --git a/regression-tests.recursor-dnssec/runtests b/regression-tests.recursor-dnssec/runtests index 600d681adf..d570c58497 100755 --- a/regression-tests.recursor-dnssec/runtests +++ b/regression-tests.recursor-dnssec/runtests @@ -21,7 +21,7 @@ export PDNSUTIL=${PDNSUTIL:-${PWD}/../pdns/pdnsutil} export PDNSRECURSOR=${PDNSRECURSOR:-${PWD}/../pdns/recursordist/pdns_recursor} export RECCONTROL=${RECCONTROL:-${PWD}/../pdns/recursordist/rec_control} -LIBFAKETIME_DEFAULT=/usr/lib/x86_64-linux-gnu/faketime/libfaketime.so.1 # ubuntu default +LIBFAKETIME_DEFAULT=/usr/lib/x86_64-linux-gnu/faketime/libfaketimeMT.so.1 # ubuntu default LIBAUTHBIND_DEFAULT=/usr/lib/authbind/libauthbind.so.1 if [ $(uname -s) = "Darwin" ]; then # macOS is not /really/ supported here; it works for some tests, and then you might need sudo. @@ -55,14 +55,9 @@ if ! "$PDNSRECURSOR" --version 2>&1 | grep Features | grep -q dnstap-framestream export NODNSTAPTESTS=1 fi -# libfstrm has a bad interaction with libfaketime on at least Ubuntu Focal. -# to run the test without LIBFAKETIME, we clear the var if it set to /bin/false -if [ "$LIBFAKETIME" = "/bin/false" ]; then - LIBFAKETIME="" -fi - -if [ "${LIBAUTHBIND}" != "" -o "${LIBFAKETIME}" != "" ]; then -LD_PRELOAD="${LIBASAN} ${LIBAUTHBIND} ${LIBFAKETIME}" nosetests -I test_WellKnown.py --with-xunit $@ +# LIBFAKETIME is only added to LD_PRELOAD by the pyton code when needed +if [ "${LIBASAN}" != "" -o "${LIBAUTHBIND}" != "" ]; then +LD_PRELOAD="${LIBASAN} ${LIBAUTHBIND}" nosetests -I test_WellKnown.py --with-xunit $@ else nosetests -I test_WellKnown.py --with-xunit $@ fi diff --git a/tasks.py b/tasks.py index 74f14b5dcb..0edc6c3f01 100644 --- a/tasks.py +++ b/tasks.py @@ -456,8 +456,7 @@ def test_dnsdist(c): @task def test_regression_recursor(c): c.run('/opt/pdns-recursor/sbin/pdns_recursor --version') - c.run('PDNSRECURSOR=/opt/pdns-recursor/sbin/pdns_recursor RECCONTROL=/opt/pdns-recursor/bin/rec_control SKIP_IPV6_TESTS=y LIBFAKETIME=/bin/false ./build-scripts/test-recursor test_RecDnstap.py') - c.run('PDNSRECURSOR=/opt/pdns-recursor/sbin/pdns_recursor RECCONTROL=/opt/pdns-recursor/bin/rec_control SKIP_IPV6_TESTS=y ./build-scripts/test-recursor -I test_RecDnstap.py') + c.run('PDNSRECURSOR=/opt/pdns-recursor/sbin/pdns_recursor RECCONTROL=/opt/pdns-recursor/bin/rec_control SKIP_IPV6_TESTS=y ./build-scripts/test-recursor') @task def test_bulk_recursor(c, threads, mthreads, shards):