Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit d809e01

Browse filesBrowse files
authored
Merge pull request #16923 from anntzer/cimacos
Test the macosx backend on Travis.
2 parents d9b722f + f41ec58 commit d809e01
Copy full SHA for d809e01

File tree

Expand file treeCollapse file tree

1 file changed

+7
-4
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+7
-4
lines changed

‎lib/matplotlib/tests/test_backends_interactive.py

Copy file name to clipboardExpand all lines: lib/matplotlib/tests/test_backends_interactive.py
+7-4Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414

1515
# Minimal smoke-testing of the backends for which the dependencies are
16-
# PyPI-installable on Travis. They are not available for all tested Python
16+
# PyPI-installable on CI. They are not available for all tested Python
1717
# versions so we don't fail on missing backends.
1818

1919
def _get_testable_interactive_backends():
@@ -28,19 +28,22 @@ def _get_testable_interactive_backends():
2828
(["tkinter"], "tkagg"),
2929
(["wx"], "wx"),
3030
(["wx"], "wxagg"),
31+
(["matplotlib.backends._macosx"], "macosx"),
3132
]:
3233
reason = None
3334
missing = [dep for dep in deps if not importlib.util.find_spec(dep)]
34-
if not os.environ.get("DISPLAY"):
35+
if sys.platform == "linux" and not os.environ.get("DISPLAY"):
3536
reason = "$DISPLAY is unset"
3637
elif missing:
3738
reason = "{} cannot be imported".format(", ".join(missing))
39+
elif backend == 'macosx' and os.environ.get('TF_BUILD'):
40+
reason = "macosx backend fails on Azure"
3841
if reason:
3942
backend = pytest.param(
4043
backend,
4144
marks=pytest.mark.skip(
4245
reason=f"Skipping {backend} because {reason}"))
43-
elif backend == 'wxagg' and sys.platform == 'darwin':
46+
elif backend.startswith('wx') and sys.platform == 'darwin':
4447
# ignore on OSX because that's currently broken (github #16849)
4548
backend = pytest.param(
4649
backend,
@@ -131,7 +134,7 @@ def test_interactive_backend(backend):
131134
assert proc.stdout.count("CloseEvent") == 1
132135

133136

134-
@pytest.mark.skipif('SYSTEM_TEAMFOUNDATIONCOLLECTIONURI' in os.environ,
137+
@pytest.mark.skipif('TF_BUILD' in os.environ,
135138
reason="this test fails an azure for unknown reasons")
136139
@pytest.mark.skipif(os.name == "nt", reason="Cannot send SIGINT on Windows.")
137140
def test_webagg():

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.