From: Nicki Křížek Date: Wed, 1 Jul 2026 13:40:07 +0000 (+0000) Subject: Move the statschannel prereq.sh check to a marker X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=9adb531a458158d6e0833e514bc23b2e5c4a986d;p=thirdparty%2Fbind9.git Move the statschannel prereq.sh check to a marker The libxml2/json-c requirement becomes with_libxml2_or_json_c. The stale Net::DNS check and the core-Perl File::Fetch check are dropped rather than carried over. Assisted-by: Claude:claude-opus-4-8 --- diff --git a/bin/tests/system/isctest/mark.py b/bin/tests/system/isctest/mark.py index 5debabb2bf6..5b62697f1fe 100644 --- a/bin/tests/system/isctest/mark.py +++ b/bin/tests/system/isctest/mark.py @@ -127,6 +127,11 @@ with_gssapi = pytest.mark.skipif( os.getenv("FEATURE_GSSAPI") != "1", reason="GSS-API support disabled in the build" ) +with_libxml2_or_json_c = pytest.mark.skipif( + os.getenv("FEATURE_LIBXML2") != "1" and os.getenv("FEATURE_JSON_C") != "1", + reason="libxml2 or json-c support is required", +) + with_fips_dh = pytest.mark.skipif( os.getenv("FEATURE_FIPS_DH") != "1", reason="FIPS mode Diffie-Hellman is required" ) diff --git a/bin/tests/system/statschannel/prereq.sh b/bin/tests/system/statschannel/prereq.sh deleted file mode 100644 index df30423dc69..00000000000 --- a/bin/tests/system/statschannel/prereq.sh +++ /dev/null @@ -1,31 +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 - -if ! ${PERL} -MNet::DNS -e ''; then - echo_i "perl Net::DNS module is required" - exit 1 -fi - -if ! ${PERL} -MFile::Fetch -e ''; then - echo_i "perl File::Fetch module is required" - exit 1 -fi - -if ! $FEATURETEST --have-libxml2 && ! $FEATURETEST --have-json-c; then - echo_i "skip: one or both of --with-libxml2 and --with-json-c required" - exit 255 -fi - -exit 0 diff --git a/bin/tests/system/statschannel/tests_sh_statschannel.py b/bin/tests/system/statschannel/tests_sh_statschannel.py index 473646cf1b3..b35427a64c4 100644 --- a/bin/tests/system/statschannel/tests_sh_statschannel.py +++ b/bin/tests/system/statschannel/tests_sh_statschannel.py @@ -11,7 +11,9 @@ import pytest -pytestmark = pytest.mark.extra_artifacts( +import isctest.mark + +EXTRA_ARTIFACTS = pytest.mark.extra_artifacts( [ "K*", "ans5/ans.run", @@ -51,6 +53,11 @@ pytestmark = pytest.mark.extra_artifacts( ] ) +pytestmark = [ + isctest.mark.with_libxml2_or_json_c, + EXTRA_ARTIFACTS, +] + def test_statschannel(run_tests_sh): run_tests_sh()