[pypy-commit] pypy json-decoder-maps: skip if there is no hypothesis

cfbolz pypy.commits at gmail.com
Tue Jun 11 07:21:30 EDT 2019


Author: Carl Friedrich Bolz-Tereick <cfbolz at gmx.de>
Branch: json-decoder-maps
Changeset: r96788:028e00604df8
Date: 2019-06-11 11:55 +0200
http://bitbucket.org/pypy/pypy/changeset/028e00604df8/

Log:	skip if there is no hypothesis

diff --git a/pypy/module/_pypyjson/test/test_simd.py b/pypy/module/_pypyjson/test/test_simd.py
--- a/pypy/module/_pypyjson/test/test_simd.py
+++ b/pypy/module/_pypyjson/test/test_simd.py
@@ -9,7 +9,10 @@
 from pypy.module._pypyjson.simd import find_end_of_string_simd_unaligned, WORD_SIZE
 from pypy.module._pypyjson.simd import find_end_of_string_simd_unaligned_no_hash
 
-from hypothesis import example, given, strategies
+try:
+    from hypothesis import example, given, strategies
+except ImportError:
+    pytest.skip("missing hypothesis!")
 
 if not USE_SIMD:
     pytest.skip("only implemented for 64 bit for now")


More information about the pypy-commit mailing list