Skip to content

Commit 2b34b68

Browse files
authored
Do not load start up file when running tests (#710)
1 parent 6cb0fb0 commit 2b34b68

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

test/runtests.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ testfiles = sort(filter(istest, readdir(testdir)))
4444

4545
@testset "$f" for f in testfiles
4646
mpiexec() do mpirun
47-
cmd(n=nprocs) = `$mpirun -n $n $(Base.julia_cmd()) $(joinpath(testdir, f))`
47+
cmd(n=nprocs) = `$mpirun -n $n $(Base.julia_cmd()) --startup-file=no $(joinpath(testdir, f))`
4848
if f == "test_spawn.jl"
4949
# Some command as the others, but always use a single process
5050
run(cmd(1))

test/test_spawn.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ exename = joinpath(Sys.BINDIR, Base.julia_exename())
99
@test isfile(exename)
1010
errors = Vector{Cint}(undef, N-1)
1111
# Ensure using consistent flags when spawning subprocesses by using same arguments as `Base.julia_cmd`.
12-
intercomm = MPI.Comm_spawn(exename, vcat(Base.julia_cmd()[2:end], joinpath(@__DIR__, "spawned_worker.jl")), N-1, MPI.COMM_WORLD, errors)
12+
intercomm = MPI.Comm_spawn(exename, vcat(Base.julia_cmd()[2:end], "--startup-file=no", joinpath(@__DIR__, "spawned_worker.jl")), N-1, MPI.COMM_WORLD, errors)
1313
@test errors == zeros(Cint,N-1)
1414
world_comm = MPI.Intercomm_merge(intercomm, false)
1515

0 commit comments

Comments
 (0)