Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions test/testsuite.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ using Test
using Adapt

test_result(@nospecialize(a), @nospecialize(b); kwargs...) = a == b
test_result(::Nothing, ::Nothing; kwargs...) = true
test_result(::Nothing, @nospecialize(b); kwargs...) = false
test_result(@nospecialize(a), ::Nothing; kwargs...) = false
test_result(a::Number, b::Number; kwargs...) = ≈(a, b; kwargs...)
test_result(a::Missing, b::Missing; kwargs...) = true
test_result(a::Number, b::Missing; kwargs...) = false
Expand Down
1 change: 1 addition & 0 deletions test/testsuite/indexing.jl
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ end
# 1D
@test compare(findfirst, AT, rand(Bool, 100))
@test compare(x->findfirst(>(0.5f0), x), AT, rand(Float32, 100))
@test compare(findfirst, AT, fill(false, 10))
let x = fill(false, 10)
@test findfirst(x) == findfirst(AT(x))
end
Expand Down