Skip to content

Commit 2419648

Browse files
Update vectorofarray_gpu.jl
1 parent e812893 commit 2419648

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

test/gpu/vectorofarray_gpu.jl

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using RecursiveArrayTools, CUDA, Test, Zygote
1+
using RecursiveArrayTools, CUDA, Test, Zygote, Adapt
22
CUDA.allowscalar(false)
33

44
# Test indexing with colon
@@ -37,3 +37,14 @@ va_cu = convert(AbstractArray, va)
3737

3838
@test va_cu isa CuArray
3939
@test size(va_cu) == size(x)
40+
41+
a = VectorOfArray([ones(2) for i in 1:3])
42+
_a = Adapt.adapt(CuArray,a)
43+
@test _a isa VectorOfArray
44+
@test _a.u isa Vector{<:CuArray}
45+
46+
b = DiffEqArray([ones(2) for i in 1:3],ones(2))
47+
_b = Adapt.adapt(CuArray,b)
48+
@test _b isa DiffEqArray
49+
@test _b.u isa Vector{<:CuArray}
50+
@test _b.t isa CuArray

0 commit comments

Comments
 (0)