Skip to content

Commit f47b1dc

Browse files
Fix deprecations in testing utilities
1 parent e058e00 commit f47b1dc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/test_solution.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ function appxtrue(sol::AbstractODESolution, sol2::TestSolution)
4646
_sol = sol2
4747
end
4848

49-
errors = Dict(:final => recursive_mean(abs.(sol[end] - _sol[end])))
49+
errors = Dict(:final => recursive_mean(abs.(sol.u[end] - _sol.u[end])))
5050
if _sol.dense
5151
timeseries_analytic = _sol(sol.t)
5252
errors[:l∞] = maximum(vecvecapply((x) -> abs.(x), sol - timeseries_analytic))
@@ -81,7 +81,7 @@ calculated.
8181
"""
8282
function appxtrue(sol::AbstractODESolution, sol2::AbstractODESolution;
8383
timeseries_errors = sol2.dense, dense_errors = sol2.dense)
84-
errors = Dict(:final => recursive_mean(abs.(sol[end] - sol2[end])))
84+
errors = Dict(:final => recursive_mean(abs.(sol.u[end] - sol2.u[end])))
8585
if sol2.dense
8686
timeseries_analytic = sol2(sol.t)
8787
errors[:l∞] = maximum(vecvecapply((x) -> abs.(x), sol - timeseries_analytic))

0 commit comments

Comments
 (0)