rL ivdZddlZddlmZddlmZddlZddlmZ ddl m Z ddl m Z mZdZd Zd Zd Zd Zy) zL Backend-loading machinery tests, using variations on the template backend. N)SimpleNamespace) MagicMock)pyplot)backend_template)FigureCanvasTemplateFigureManagerTemplatectjdttjj t k(sJy)Ntemplate)mplusetypepltfigurecanvasrl/mnt/ssd/data/python-lab/Trading/venv/lib/python3.12/site-packages/matplotlib/tests/test_backend_template.pytest_load_templaters.GGJ  ## $(< << z#test_load_old_api..s$ d!=f!= > Ermpl_test_backendmodule://mpl_test_backendr)rvarsrr rFigurenew_figure_managersetitemsysmodulesr r rrrdraw_if_interactive) monkeypatchrs rtest_load_old_apir&s&@.>)?@'*zz'8'8 E' %79IJGG '(  ## $(< << <rc6tditt}t}|j |j d||j tjd|tjdtj|jy)N pyplot_showrrrrrrrsetattrrr!r"r#r r rshowassert_called_withr%r mock_shows r test_showr/!s&@.>)?@ I.. yJ %79IJGG '(HHJ   "rc&tditt}t}|j |d|d|j t jd|tjdtj|jy)Nr+F)raisingrrr) rrrrr*r!r"r#r r rr+r,r-s rtest_show_old_global_apir3,so&@.>)?@ I(&)UK %79IJGG '(HHJ   "rc6tditt}t}|j |j d||j tjd|tjdtj|jy)Nr(mpl_Test_Backendzmodule://mpl_Test_Backendrr)r-s rtest_load_case_sensitiver66r0r)__doc__r"typesr unittest.mockr matplotlibr rrmatplotlib.backendsr$matplotlib.backends.backend_templaterrrr&r/r3r6rrrr=s< !#$01= ###r