Skip to content

Commit

Permalink
Add test for --pkgimages=no
Browse files Browse the repository at this point in the history
  • Loading branch information
gbaraldi committed Jan 12, 2023
1 parent de4a19c commit 8eaa163
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions test/loading.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1025,6 +1025,27 @@ end
end
end

@testset "--pkgimages=no" begin
old_depot_path = copy(DEPOT_PATH)
try
tmp = mktempdir()
push!(empty!(DEPOT_PATH), joinpath(tmp, "depot"))

proj = joinpath(@__DIR__, "project", "Extensions", "HasDepWithExtensions.jl")
for compile in (`--pkgimages=no`, `--pkgimages=no`) # Once when requiring precomilation, once where it is already precompiled
cmd = `$(Base.julia_cmd()) $compile --project=$proj --startup-file=no -e '
begin
using HasExtensions
using HasDepWithExtensions
end
'`
@test success(cmd)
end
finally
copy!(DEPOT_PATH, old_depot_path)
end
end


empty!(Base.DEPOT_PATH)
append!(Base.DEPOT_PATH, original_depot_path)

0 comments on commit 8eaa163

Please sign in to comment.