Skip to content

Commit

Permalink
Fix deprecation warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
ArnoStrouwen committed Jan 24, 2024
1 parent b678985 commit 64a4aa2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
4 changes: 2 additions & 2 deletions test/basic_indexing.jl
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ testvb = deepcopy(testva)
@test_deprecated testva[1:2]
@test_deprecated testva[begin]
@test_deprecated testva[end]
@test testva[begin] == testva[:, begin] == first(testva)
@test testva[end] == testva[:, end] == last(testva)
@test testva[:, begin] == first(testva)
@test testva[:, end] == last(testva)
@test testa[:, 1] == recs[1]
@test testva.u == recs
@test testva[: ,2:end] == VectorOfArray([recs[i] for i in 2:length(recs)])
Expand Down
8 changes: 3 additions & 5 deletions test/interface_tests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -98,12 +98,10 @@ bool_idx = rand(Bool, 10)
for (voaidx, arridx) in [
((:,), (:,)),
((3:5,), (3:5,)),
((:, 3:5), (3:5,)),
((1, 3:5), (3:5,)),
((:, bool_idx), (bool_idx,))
((bool_idx,), (bool_idx,))
]
arr_view = view(arrvc, arridx...)
voa_view = view(testvc, voaidx...)
voa_view = view(testvc.u, voaidx...)
@test size(arr_view) == size(voa_view)
@test all(arr_view .== voa_view)
end
Expand Down Expand Up @@ -229,7 +227,7 @@ function f(u1,u2,u3)
u3 .= u1 .+ u2
end
f(u1,u2,u3)
@test (@allocated f(u1,u2,u3)) == 0
@test (@allocated f(u1,u2,u3)) == 0

yy = [2.0 1.0; 2.0 1.0]
zz = x .+ yy
Expand Down

0 comments on commit 64a4aa2

Please sign in to comment.