From 29398087423385fc28d762e88f359782bfd26144 Mon Sep 17 00:00:00 2001 From: Sathvik Bhagavan Date: Mon, 6 May 2024 07:58:28 +0000 Subject: [PATCH] test: update tests caused by AbstractVector subtype removal --- test/interface.jl | 2 -- test/online_tests.jl | 8 ++++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/test/interface.jl b/test/interface.jl index 3b17a1ca..b777471f 100644 --- a/test/interface.jl +++ b/test/interface.jl @@ -3,7 +3,6 @@ u = 2.0collect(1:10) t = 1.0collect(1:10) A = LinearInterpolation(u, t) -@test length(A) == 20 for i in 1:10 @test u[i] == A[i] end @@ -13,7 +12,6 @@ for i in 11:20 end A = LinearInterpolation{false}(u, t, true) -@test length(A) == 10 for i in 1:10 @test u[i] == A[i] end diff --git a/test/online_tests.jl b/test/online_tests.jl index 6103cfc4..cc4d4c84 100644 --- a/test/online_tests.jl +++ b/test/online_tests.jl @@ -6,9 +6,13 @@ u = [0, 1, 0] for di in [LinearInterpolation, QuadraticInterpolation, ConstantInterpolation] li = di(copy(u), copy(t)) append!(li, u, t) - @test li == di(vcat(u, u), vcat(t, t)) + li2 = di(vcat(u, u), vcat(t, t)) + @test li.u == li2.u + @test li.t == li2.t li = di(copy(u), copy(t)) push!(li, 1, 4) - @test li == di(vcat(u, 1), vcat(t, 4)) + li2 = di(vcat(u, 1), vcat(t, 4)) + @test li.u == li2.u + @test li.t == li2.t end