(*args, **kwargs)
| 84 | # This wrapper wraps around `st.floats` and |
| 85 | # sets width parameters to 32 if version is newer than 3.67.0 |
| 86 | def floats(*args, **kwargs): |
| 87 | |
| 88 | width_supported = hypothesis.version.__version_info__ >= (3, 67, 0) |
| 89 | if 'width' in kwargs and not width_supported: |
| 90 | kwargs.pop('width') |
| 91 | |
| 92 | if 'width' not in kwargs and width_supported: |
| 93 | kwargs['width'] = 32 |
| 94 | if kwargs.get('min_value', None) is not None: |
| 95 | kwargs['min_value'] = to_float32(kwargs['min_value']) |
| 96 | if kwargs.get('max_value', None) is not None: |
| 97 | kwargs['max_value'] = to_float32(kwargs['max_value']) |
| 98 | |
| 99 | return st.floats(*args, **kwargs) |
| 100 | |
| 101 | |
| 102 | hypothesis.settings.register_profile( |
no test coverage detected
searching dependent graphs…