blob: def9de294b373afa0f97c84ae77da24c2459eb72 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
try:
from hypothesis import given
HAS_HYPOTHESIS = True
except ImportError:
HAS_HYPOTHESIS = False
from unittest import mock
def given(*_, **__): # type: ignore
"""Dummy implementation to make pytest collection pass"""
@mock.Mock # Add mock to fulfill the expected hypothesis value
def run_test(item):
return item
return run_test
__all__ = ["given", "HAS_HYPOTHESIS"]
|