Skip to content

Commit

Permalink
Fix convergence plot tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sarthak-dv committed Apr 7, 2024
1 parent cfca84c commit efa604a
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions tardis/visualization/tools/tests/test_convergence_plot.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for Convergence Plots."""

from copy import deepcopy

import pytest
Expand Down Expand Up @@ -143,7 +144,9 @@ def test_update_plasma_plots(convergence_plots):
# check values for t_rad subplot
assert convergence_plots.plasma_plot.data[index].xaxis == "x"
assert convergence_plots.plasma_plot.data[index].yaxis == "y"
assert convergence_plots.plasma_plot.data[index].y == tuple(t_rad_val)
assert (
convergence_plots.plasma_plot.data[index].y[:-1] == tuple(t_rad_val)
).all()
assert convergence_plots.plasma_plot.data[index].x == tuple(
velocity.to(u.km / u.s).value
)
Expand All @@ -152,7 +155,9 @@ def test_update_plasma_plots(convergence_plots):
# check values for w subplot
assert convergence_plots.plasma_plot.data[index].xaxis == "x2"
assert convergence_plots.plasma_plot.data[index].yaxis == "y2"
assert convergence_plots.plasma_plot.data[index].y == tuple(w_val)
assert (
convergence_plots.plasma_plot.data[index].y[:-1] == tuple(w_val)
).all()
assert convergence_plots.plasma_plot.data[index].x == tuple(
velocity.to(u.km / u.s).value
)
Expand Down

0 comments on commit efa604a

Please sign in to comment.