Skip to content

Backport PR #23095: Try to unbreak CI by xfailing OSX Tk tests #23194

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions lib/matplotlib/tests/test_backend_tk.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ def _isolated_tk_test(success_count, func=None):
# Remove decorators.
source = re.search(r"(?ms)^def .*", inspect.getsource(func)).group(0)

@pytest.mark.xfail( # GitHub issue #23094
sys.platform == 'darwin',
reason="Tk version mismatch on OSX CI"
)
@functools.wraps(func)
def test_func():
try:
Expand Down
6 changes: 6 additions & 0 deletions lib/matplotlib/tests/test_backends_interactive.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ def _get_testable_interactive_backends():
elif env["MPLBACKEND"].startswith('wx') and sys.platform == 'darwin':
# ignore on OSX because that's currently broken (github #16849)
marks.append(pytest.mark.xfail(reason='github #16849'))
elif env["MPLBACKEND"] == "tkagg" and sys.platform == 'darwin':
marks.append( # GitHub issue #23094
pytest.mark.xfail(reason="Tk version mismatch on OSX CI"))
envs.append(pytest.param(env, marks=marks, id=str(env)))
return envs

Expand Down Expand Up @@ -231,6 +234,9 @@ def _test_thread_impl():
reason='PyPy does not support Tkinter threading: '
'https://foss.heptapod.net/pypy/pypy/-/issues/1929',
strict=True))
elif backend == "tkagg" and sys.platform == "darwin":
param.marks.append( # GitHub issue #23094
pytest.mark.xfail("Tk version mismatch on OSX CI"))


@pytest.mark.parametrize("env", _thread_safe_backends)
Expand Down