]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Make hypothesis optional for system tests
authorNicki Křížek <nicki@isc.org>
Tue, 6 Aug 2024 15:14:21 +0000 (17:14 +0200)
committerPetr Špaček <pspacek@isc.org>
Wed, 7 Aug 2024 11:00:24 +0000 (11:00 +0000)
Ensure that system tests can be executed without Python hypothesis
package.

(cherry picked from commit e6a7695600764d6e8f37556d0dd5ecfb44d73fe3)

bin/tests/system/isctest/hypothesis/__init__.py

index 0bb73f3babead02557cc657cfa5f13be30789bc5..3ae0deeb24d3de1b79a59a87fa30bea719bc8f20 100644 (file)
@@ -9,5 +9,10 @@
 # See the COPYRIGHT file distributed with this work for additional
 # information regarding copyright ownership.
 
-from . import settings
-from . import strategies
+try:
+    import hypothesis as _
+except ImportError:
+    pass
+else:
+    from . import settings
+    from . import strategies