Skip to content

Commit 198d7e3

Browse files
committed
Next try
1 parent 7f6e6e9 commit 198d7e3

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

ext/VortexStepMethodControlPlotsExt.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ Display a plot at specified DPI.
9292
# Keyword arguments
9393
- `dpi`: Dots per inch for the figure (default: 130)
9494
"""
95-
function VortexStepMethod.show_plot(fig; dpi=130)
95+
function VortexStepMethod.show_plot(fig::plt.Figure; dpi=130)
9696
fig.set_dpi(dpi)
9797
plt.display(fig)
9898
end

test/plotting/test_plotting.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,11 @@ end
8888
if backend == "Makie"
8989
@test hasmethod(VortexStepMethod.show_plot, Tuple{Figure})
9090
@test_throws MethodError VortexStepMethod.show_plot(nothing)
91+
@test_nowarn VortexStepMethod.show_plot(fig)
92+
else
93+
FigType = plt.Figure
94+
@test hasmethod(VortexStepMethod.show_plot, Tuple{FigType})
95+
@test_throws MethodError VortexStepMethod.show_plot(nothing)
9196
end
9297

9398
@test isfile(joinpath(save_dir,

0 commit comments

Comments
 (0)