Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix nightly CI tests #810

Merged
merged 4 commits into from
Sep 9, 2020
Merged
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
9 changes: 8 additions & 1 deletion test/ambiguities.jl
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,11 @@ const allowable_ambiguities =
1
end

@test length(detect_ambiguities(Base, LinearAlgebra, StaticArrays)) <= allowable_ambiguities
if v"1.6.0-DEV.816" <= VERSION < v"1.6.0-rc"
# Revisit in 1.6.0-rc1 or before. See
# https://github.com/JuliaLang/julia/pull/36962
# https://github.com/JuliaLang/julia/issues/36951
@test_broken length(detect_ambiguities(#=LinearAlgebra, =#StaticArrays)) <= allowable_ambiguities
else
@test length(detect_ambiguities(Base, LinearAlgebra, StaticArrays)) <= allowable_ambiguities
end
6 changes: 5 additions & 1 deletion test/core.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@
@testset "Type parameter errors" begin
# (not sure what type of exception these should be?)
@test_throws Exception SVector{1.0,Int}((1,))
@test_throws DimensionMismatch("No precise constructor for SArray{Tuple{2},$Int,1,2} found. Length of input was 1.") SVector{2,Int}((1,))
@static if VERSION < v"1.6-"
@test_throws DimensionMismatch("No precise constructor for SArray{Tuple{2},$Int,1,2} found. Length of input was 1.") SVector{2,Int}((1,))
else
@test_throws DimensionMismatch("No precise constructor for SVector{2, $Int} found. Length of input was 1.") SVector{2,Int}((1,))
end
@test_throws Exception SVector{1,3}((1,))

@test_throws Exception SMatrix{1.0,1,Int,1}((1,))
Expand Down
11 changes: 10 additions & 1 deletion test/matrix_multiply_add.jl
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,16 @@ function test_multiply_add(N1,N2,ArrayType=MArray)
mul!(b,At,c,1.0,2.0)
@test b ≈ 5A'c

@test_noalloc mul!(c,A,b)
@static if VERSION < v"1.5-"
@test_noalloc mul!(c,A,b)
else
if !(ArrayType <: SizedArray)
@test_noalloc mul!(c,A,b)
else
mul!(c,A,b)
@test_broken(@allocated(mul!(c,A,b)) == 0)
end
end
bmark = @benchmark mul!($c,$A,$b,$α,$β) samples=10 evals=10
@test minimum(bmark).allocs == 0
# @test_noalloc mul!(c, A, b, α, β) # records 32 bytes
Expand Down