From 43b60bf5ee1d963b0fce3933c69b7b4124a96749 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicki=20K=C5=99=C3=AD=C5=BEek?= Date: Thu, 3 Jul 2025 14:40:06 +0200 Subject: [PATCH] Allow dnstap system test rerun on freebsd13 The check "unix socket message counts" sometimes fails with "dnstap output file smaller than expected". This only happens on freebsd13 and can't be reproduced easily. There was an attempt to decrease the required file size in the past, but apparently, the issue can still occur. (cherry picked from commit 34867e16936f79905b7189bd7d51248527e57ce3) --- bin/tests/system/dnstap/tests_sh_dnstap.py | 1 + bin/tests/system/isctest/mark.py | 5 +++++ bin/tests/system/timeouts/tests_tcp_timeouts.py | 7 +------ 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/bin/tests/system/dnstap/tests_sh_dnstap.py b/bin/tests/system/dnstap/tests_sh_dnstap.py index 5d4d7a9e9e..d1de2e0efa 100644 --- a/bin/tests/system/dnstap/tests_sh_dnstap.py +++ b/bin/tests/system/dnstap/tests_sh_dnstap.py @@ -26,5 +26,6 @@ pytestmark = pytest.mark.extra_artifacts( ) +@isctest.mark.flaky(max_runs=2, rerun_filter=isctest.mark.is_host_freebsd_13) def test_dnstap(run_tests_sh): run_tests_sh() diff --git a/bin/tests/system/isctest/mark.py b/bin/tests/system/isctest/mark.py index 115d68ac51..25408977d7 100644 --- a/bin/tests/system/isctest/mark.py +++ b/bin/tests/system/isctest/mark.py @@ -13,6 +13,7 @@ import os from pathlib import Path +import platform import shutil import ssl import subprocess @@ -54,6 +55,10 @@ def is_dnsrps_available(): return True +def is_host_freebsd_13(*_): + return platform.system() == "FreeBSD" and platform.release().startswith("13") + + have_libxml2 = pytest.mark.skipif( not feature_test("--have-libxml2"), reason="libxml2 support disabled in the build" ) diff --git a/bin/tests/system/timeouts/tests_tcp_timeouts.py b/bin/tests/system/timeouts/tests_tcp_timeouts.py index 1750715ce0..1fe1088a69 100644 --- a/bin/tests/system/timeouts/tests_tcp_timeouts.py +++ b/bin/tests/system/timeouts/tests_tcp_timeouts.py @@ -13,7 +13,6 @@ # pylint: disable=unused-variable -import platform import socket import time @@ -68,11 +67,7 @@ def test_initial_timeout(named_port): raise EOFError from e -def is_host_freebsd_13(*_): - return platform.system() == "FreeBSD" and platform.release().startswith("13") - - -@isctest.mark.flaky(max_runs=2, rerun_filter=is_host_freebsd_13) +@isctest.mark.flaky(max_runs=2, rerun_filter=isctest.mark.is_host_freebsd_13) def test_idle_timeout(named_port): # # The idle timeout is 5 seconds, so the third message should fail