Skip to content

Commit

Permalink
fix a seed for rand in a Lapack test (fix JuliaLang#24155) (JuliaLang…
Browse files Browse the repository at this point in the history
…#24211)

The seed was originally globally fixed in this file, but then locally scoped
as a result of JuliaLang#16940. But it was needed in the "sysv" testset.
  • Loading branch information
rfourquet authored and fredrikekre committed Oct 20, 2017
1 parent ac736bb commit 3b98d23
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions test/linalg/lapack.jl
Original file line number Diff line number Diff line change
Expand Up @@ -425,13 +425,15 @@ end

@testset "sysv" begin
@testset for elty in (Float32, Float64, Complex64, Complex128)
A = rand(elty,10,10)
A = A + A.' #symmetric!
b = rand(elty,10)
c = A \ b
b,A = LAPACK.sysv!('U',A,b)
@test b c
@test_throws DimensionMismatch LAPACK.sysv!('U',A,rand(elty,11))
guardsrand(123) do
A = rand(elty,10,10)
A = A + A.' #symmetric!
b = rand(elty,10)
c = A \ b
b,A = LAPACK.sysv!('U',A,b)
@test b c
@test_throws DimensionMismatch LAPACK.sysv!('U',A,rand(elty,11))
end
end
end

Expand Down

0 comments on commit 3b98d23

Please sign in to comment.