JuliaInv / MUMPSjInv.jl

MUMPS interface for Julia
18 stars 15 forks source link

`TestTwoSystemParallel` crashes during `Pkg.test("MUMPS") when it shouldn't #14

Closed Pbellive closed 7 years ago

Pbellive commented 7 years ago

Line 23 of testTwoSystemParallel.jl is

@test nworkers()>=3

If you have enough workers and just include the file everything works (on Julia 0.6) but if you run Pkg.test("MUMPS") the code fails with the following error

julia> Pkg.test("MUMPS")
INFO: Testing MUMPS
test MUMPS
Test for real SPD matrix: one rhs
Test for real SPD matrix: multiple rhs
Test for complex symmetric matrix: one rhs
Test for complex symmetric matrix: multiple rhs
DONE!
Factorize complex matrix
elapsed time: 0.342118291 seconds
Factorize real matrix
elapsed time: 0.666947092 seconds
Solve complex system
elapsed time: 0.088723686 seconds
Solve real system
elapsed time: 0.163119615 seconds
Free memory
DONE!
ERROR: LoadError: LoadError: MethodError: no method matching isless(::Base.Distributed.#nworkers, ::Int64)                                                                      
Closest candidates are:
  isless(::AbstractFloat, ::Real) at operators.jl:98
  isless(::Real, ::Real) at operators.jl:266
Stacktrace:
 [1] <(::Function, ::Int64) at ./operators.jl:194
 [2] include_from_node1(::String) at ./loading.jl:569
 [3] include(::String) at ./sysimg.jl:14
 [4] include_from_node1(::String) at ./loading.jl:569
 [5] include(::String) at ./sysimg.jl:14
 [6] process_options(::Base.JLOptions) at ./client.jl:305
 [7] _start() at ./client.jl:371
while loading /home/patrick/.julia/v0.6/MUMPS/test/testTwoSystemParallel.jl, in expression starting on line 2
while loading /home/patrick/.julia/v0.6/MUMPS/test/runtests.jl, in expression starting on line 4

even though there were four workers launched when I ran the tests. This can be fixed by adding workers inside the tests. Preparing a PR with the fix.