We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent faa38bf commit 9cb90f3Copy full SHA for 9cb90f3
test/conftest.py
@@ -1,4 +1,8 @@
1
from pathlib import Path
2
+from platform import system
3
+
4
+import pytest
5
+from modflow_devtools.misc import is_in_ci
6
7
pytest_plugins = ["modflow_devtools.fixtures"]
8
@@ -8,6 +12,15 @@
12
EXCLUDED_EXAMPLES = []
9
13
10
14
15
+@pytest.fixture(scope="session", autouse=True)
16
+def patch_macos_ci_matplotlib():
17
+ # use noninteractive matplotlib backend if in Mac OS CI to avoid pytest-xdist node failure
18
+ if is_in_ci() and system().lower() == "darwin":
19
+ import matplotlib
20
21
+ matplotlib.use("agg")
22
23
11
24
def pytest_generate_tests(metafunc):
25
if "example_script" in metafunc.fixturenames:
26
scripts = {
0 commit comments