From c4e1d5d3a6272e428e3cb015f422145198adf983 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Thu, 15 Jun 2023 20:06:38 -0400 Subject: [PATCH] TST: xfail Tk test on Python 3.9 Azure macOS also --- lib/matplotlib/tests/test_backend_tk.py | 2 +- lib/matplotlib/tests/test_backends_interactive.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/matplotlib/tests/test_backend_tk.py b/lib/matplotlib/tests/test_backend_tk.py index 1e6d714b1de9..fac315b2b6f4 100644 --- a/lib/matplotlib/tests/test_backend_tk.py +++ b/lib/matplotlib/tests/test_backend_tk.py @@ -40,7 +40,7 @@ def _isolated_tk_test(success_count, func=None): ) @pytest.mark.xfail( # https://github.com/actions/setup-python/issues/649 'TF_BUILD' in os.environ and sys.platform == 'darwin' and - sys.version_info[:2] == (3, 10), + sys.version_info[:2] < (3, 11), reason='Tk version mismatch on Azure macOS CI' ) @functools.wraps(func) diff --git a/lib/matplotlib/tests/test_backends_interactive.py b/lib/matplotlib/tests/test_backends_interactive.py index bc0b7c75b922..4d9d30da50d3 100644 --- a/lib/matplotlib/tests/test_backends_interactive.py +++ b/lib/matplotlib/tests/test_backends_interactive.py @@ -64,7 +64,7 @@ def _get_testable_interactive_backends(): # ignore on OSX because that's currently broken (github #16849) marks.append(pytest.mark.xfail(reason='github #16849')) elif (env['MPLBACKEND'] == 'tkagg' and 'TF_BUILD' in os.environ and - sys.platform == 'darwin' and sys.version_info[:2] == (3, 10)): + sys.platform == 'darwin' and sys.version_info[:2] < (3, 11)): marks.append( # https://github.com/actions/setup-python/issues/649 pytest.mark.xfail(reason='Tk version mismatch on Azure macOS CI')) envs.append( @@ -274,7 +274,7 @@ def _test_thread_impl(): 'https://foss.heptapod.net/pypy/pypy/-/issues/1929', strict=True)) elif (backend == 'tkagg' and 'TF_BUILD' in os.environ and - sys.platform == 'darwin' and sys.version_info[:2] == (3, 10)): + sys.platform == 'darwin' and sys.version_info[:2] < (3, 11)): param.marks.append( # https://github.com/actions/setup-python/issues/649 pytest.mark.xfail('Tk version mismatch on Azure macOS CI')) @@ -547,7 +547,7 @@ def _test_number_of_draws_script(): param.marks.append( pytest.mark.skip("wx does not support blitting")) elif (backend == 'tkagg' and 'TF_BUILD' in os.environ and - sys.platform == 'darwin' and sys.version_info[:2] == (3, 10)): + sys.platform == 'darwin' and sys.version_info[:2] < (3, 11)): param.marks.append( # https://github.com/actions/setup-python/issues/649 pytest.mark.xfail('Tk version mismatch on Azure macOS CI') )