]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Move libnghttp2 prereq.sh checks to a with_libnghttp2 marker
authorNicki Křížek <nicki@isc.org>
Wed, 1 Jul 2026 13:40:06 +0000 (13:40 +0000)
committerNicki Křížek <nicki@isc.org>
Fri, 10 Jul 2026 11:17:41 +0000 (13:17 +0200)
Gates proxy, transport_change and the doth modules. doth also needs
FIPS-DH, so its prereq.sh keeps that check for now.

Assisted-by: Claude:claude-opus-4-8
bin/tests/system/doth/prereq.sh
bin/tests/system/doth/tests_gnutls.py
bin/tests/system/doth/tests_malicious.py
bin/tests/system/doth/tests_sh_doth.py
bin/tests/system/doth/tests_sslyze.py
bin/tests/system/isctest/mark.py
bin/tests/system/proxy/prereq.sh [deleted file]
bin/tests/system/proxy/tests_sh_proxy.py
bin/tests/system/transport_change/prereq.sh [deleted file]
bin/tests/system/transport_change/tests_sh_transport_change.py

index fe62dcb15ac3a3c4b9e697bd45cfbcbe78bf271d..4dabc5b3e8491663783187e66e7f237847df399d 100644 (file)
 
 . ../conf.sh
 
-$FEATURETEST --with-libnghttp2 || {
-  echo_i "This test requires libnghttp2 support." >&2
-  exit 255
-}
-
 $FEATURETEST --have-fips-dh || {
   echo_i "FIPS mode Diffie-Hellman not working - skipping doth test"
   exit 255
index 7053311debdc8994f90176da257c4729c84187fe..81eb4980d4bd2faba12d716c157013020472b32f 100644 (file)
@@ -24,14 +24,20 @@ import dns.rdatatype
 import pytest
 
 import isctest
+import isctest.mark
 
-pytestmark = pytest.mark.extra_artifacts(
+EXTRA_ARTIFACTS = pytest.mark.extra_artifacts(
     [
         "gnutls-cli.*",
         "ns*/example*.db",
     ]
 )
 
+pytestmark = [
+    isctest.mark.with_libnghttp2,
+    EXTRA_ARTIFACTS,
+]
+
 
 def test_gnutls_cli_query(gnutls_cli_executable, named_tlsport):
     # Prepare the example/SOA query which will be sent over TLS.
index 7529f2b7e19db051e5dc17fca1538c702cab0a83..34b26b445eeba6029e2897edf79e6be5a594d373 100644 (file)
@@ -18,6 +18,12 @@ from h2.settings import SettingCodes
 
 import dns.message
 
+import isctest.mark
+
+pytestmark = [
+    isctest.mark.with_libnghttp2,
+]
+
 
 def test_settings_frame_flood(ns1, named_httpsport):
     msg = dns.message.make_query(".", "SOA")
index 69e92fab4c1d769bfe156fcaa19b00634dc75646..28866395580734d2b9a893708e57ddc79e4a82ec 100644 (file)
@@ -11,7 +11,9 @@
 
 import pytest
 
-pytestmark = pytest.mark.extra_artifacts(
+import isctest.mark
+
+EXTRA_ARTIFACTS = pytest.mark.extra_artifacts(
     [
         "dig.out.*",
         "headers.*",
@@ -19,6 +21,11 @@ pytestmark = pytest.mark.extra_artifacts(
     ]
 )
 
+pytestmark = [
+    isctest.mark.with_libnghttp2,
+    EXTRA_ARTIFACTS,
+]
+
 
 def test_doth(run_tests_sh):
     run_tests_sh()
index 33d916abf2b587b86517f697635f96b107dfba5e..9ab801d9423506a1ebf943d6c720c087e010ff12 100644 (file)
@@ -18,14 +18,20 @@ import subprocess
 import pytest
 
 import isctest
+import isctest.mark
 
-pytestmark = pytest.mark.extra_artifacts(
+EXTRA_ARTIFACTS = pytest.mark.extra_artifacts(
     [
         "sslyze.log.*",
         "ns*/example*.db",
     ]
 )
 
+pytestmark = [
+    isctest.mark.with_libnghttp2,
+    EXTRA_ARTIFACTS,
+]
+
 
 def is_pid_alive(pid):
     try:
index fd9e22337019e628786d02d47e11ea873a4d6288..09e27548de64f57c1636af412b324b0caf5632a1 100644 (file)
@@ -108,6 +108,11 @@ with_json_c = pytest.mark.skipif(
     os.getenv("FEATURE_JSON_C") != "1", reason="json-c support disabled in the build"
 )
 
+with_libnghttp2 = pytest.mark.skipif(
+    os.getenv("FEATURE_LIBNGHTTP2") != "1",
+    reason="libnghttp2 support disabled in the build",
+)
+
 softhsm2_environment = pytest.mark.skipif(
     not (
         os.getenv("SOFTHSM2_CONF")
diff --git a/bin/tests/system/proxy/prereq.sh b/bin/tests/system/proxy/prereq.sh
deleted file mode 100644 (file)
index 225c1e2..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/bin/sh
-
-# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
-#
-# SPDX-License-Identifier: MPL-2.0
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0.  If a copy of the MPL was not distributed with this
-# file, you can obtain one at https://mozilla.org/MPL/2.0/.
-#
-# See the COPYRIGHT file distributed with this work for additional
-# information regarding copyright ownership.
-
-. ../conf.sh
-
-$FEATURETEST --with-libnghttp2 || {
-  echo_i "This test requires libnghttp2 support." >&2
-  exit 255
-}
-
-exit 0
index 98239f282df304208e8d4131181792e157cbf9ee..abe0ae3163a717889c27d80c07f83a3d94ded416 100644 (file)
 
 import pytest
 
-pytestmark = pytest.mark.extra_artifacts(
+import isctest.mark
+
+EXTRA_ARTIFACTS = pytest.mark.extra_artifacts(
     [
         "dig.out.*",
         "ns*/example.db",
     ]
 )
 
+pytestmark = [
+    isctest.mark.with_libnghttp2,
+    EXTRA_ARTIFACTS,
+]
+
 
 def test_proxy(run_tests_sh):
     run_tests_sh()
diff --git a/bin/tests/system/transport_change/prereq.sh b/bin/tests/system/transport_change/prereq.sh
deleted file mode 100644 (file)
index 0c19f11..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/sh
-
-# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
-#
-# SPDX-License-Identifier: MPL-2.0
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0.  If a copy of the MPL was not distributed with this
-# file, you can obtain one at https://mozilla.org/MPL/2.0/.
-#
-# See the COPYRIGHT file distributed with this work for additional
-# information regarding copyright ownership.
-
-# shellcheck disable=SC1091
-. ../conf.sh
-
-$FEATURETEST --with-libnghttp2 || {
-  echo_i "This test requires libnghttp2 support." >&2
-  exit 255
-}
-
-exit 0
index a4370b670ec161435fcc1d82058c4420e8716a08..73fa34fdc02a9c7cc88784f9c4a0862ac2d85aac 100644 (file)
 
 import pytest
 
-pytestmark = pytest.mark.extra_artifacts(
+import isctest.mark
+
+EXTRA_ARTIFACTS = pytest.mark.extra_artifacts(
     [
         "dig.out.*",
         "ns1/example.db",
     ]
 )
 
+pytestmark = [
+    isctest.mark.with_libnghttp2,
+    EXTRA_ARTIFACTS,
+]
+
 
 def test_transport_change(run_tests_sh):
     run_tests_sh()