From: Jason Ish Date: Fri, 12 Jan 2018 14:21:05 +0000 (-0600) Subject: allow optional reason for skip in non-features X-Git-Tag: suricata-6.0.4~540 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8cd5c0b79ad20e17db6e7647e12e30ba3341158a;p=thirdparty%2Fsuricata-verify.git allow optional reason for skip in non-features --- diff --git a/README.md b/README.md index 1ce47a0d1..3d8fa7a12 100644 --- a/README.md +++ b/README.md @@ -62,4 +62,4 @@ requires: # Require that Suricata not be built with specific features. not-features: - - RUST + RUST: option reason diff --git a/run.py b/run.py index bd85ece4b..8a1dec318 100755 --- a/run.py +++ b/run.py @@ -102,8 +102,12 @@ class TestConfig: if "not-features" in requires: for feature in requires["not-features"]: if self.suricata_config.has_feature(feature): - raise UnsatisfiedRequirementError( - "not for feature %s" % (feature)) + if requires["not-features"][feature]: + comment = "%s" % ( + requires["not-features"][feature]) + else: + comment = "not for feature %s" % (feature) + raise UnsatisfiedRequirementError(comment) if "env" in requires: for env in requires["env"]: diff --git a/tests/dns-lua-rules/test.yaml b/tests/dns-lua-rules/test.yaml index c76354aab..79ff97513 100644 --- a/tests/dns-lua-rules/test.yaml +++ b/tests/dns-lua-rules/test.yaml @@ -2,7 +2,7 @@ requires: features: - HAVE_LUA not-features: - - RUST + RUST: known issue with feature RUST checks: - filter: diff --git a/tests/dns-udp-dns-log-unanswered/test.yaml b/tests/dns-udp-dns-log-unanswered/test.yaml index dfbdcfb53..d00be7485 100644 --- a/tests/dns-udp-dns-log-unanswered/test.yaml +++ b/tests/dns-udp-dns-log-unanswered/test.yaml @@ -1,4 +1,4 @@ requires: # Test will be skipped if any of these features are present. not-features: - - RUST + RUST: diff --git a/tests/dns-udp-unsolicited-response/test.yaml b/tests/dns-udp-unsolicited-response/test.yaml index 6aec7b1ab..0546b5b1e 100644 --- a/tests/dns-udp-unsolicited-response/test.yaml +++ b/tests/dns-udp-unsolicited-response/test.yaml @@ -1,6 +1,6 @@ requires: # Test will be skipped if any of these features are present. not-features: - - RUST + RUST: features: - HAVE_LIBJANSSON