Skip to content

Commit

Permalink
Merge pull request #370 from neutrinoceros/rfc/avoid_pyplot_in_tests_4
Browse files Browse the repository at this point in the history
TST: avoid pyplot interface in tests (3/3)
  • Loading branch information
neutrinoceros authored Nov 2, 2024
2 parents a403cec + f5f158e commit 8af9783
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from pathlib import Path

import matplotlib
import matplotlib.pyplot as plt
import pytest
from matplotlib.figure import Figure


def pytest_configure(config): # noqa: ARG001
Expand All @@ -26,6 +26,6 @@ def simulation_dir(test_data_dir, request):

@pytest.fixture()
def temp_figure_and_axis():
fig, ax = plt.subplots()
fig = Figure()
ax = fig.add_subplot()
yield (fig, ax)
plt.close(fig)

0 comments on commit 8af9783

Please sign in to comment.