-
Notifications
You must be signed in to change notification settings - Fork 0
/
conftest.py
46 lines (36 loc) · 1.17 KB
/
conftest.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import pytest
# The doctests in these files fail due to either:
# - Non-required dependencies not being installed
# - Imported doctests due to pulling the docstrings from other packages
# (e.g. `numpy`). No need to run these doctests.
collect_ignore = [
"dask/bytes/hdfs3.py",
"dask/bytes/pyarrow.py",
"dask/bytes/s3.py",
"dask/array/ghost.py",
"dask/array/fft.py",
"dask/dataframe/io/io.py",
"dask/dataframe/io/parquet/arrow.py",
"dask/dot.py",
]
collect_ignore_glob = []
try:
import numpy # noqa: F401
except ImportError:
collect_ignore_glob.append("dask/array/*")
try:
import pandas # noqa: F401
except ImportError:
collect_ignore_glob.append("dask/dataframe/*")
try:
import scipy # noqa: F401
except ImportError:
collect_ignore.append("dask/array/stats.py")
def pytest_addoption(parser):
parser.addoption("--runslow", action="store_true", help="run slow tests")
def pytest_runtest_setup(item):
if "slow" in item.keywords and not item.config.getoption("--runslow"):
pytest.skip("need --runslow option to run")
pytest.register_assert_rewrite(
"dask.array.utils", "dask.dataframe.utils", "dask.bag.utils"
)