Skip to content

Commit

Permalink
fix workaround
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshuaLampert committed May 30, 2023
1 parent cf318da commit 1e183f0
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
10 changes: 0 additions & 10 deletions test/configure_packages.jl
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,3 @@ Preferences.set_preferences!(
"libhdf5_hl" => joinpath(JULIA_HDF5_PATH, "libhdf5_hl.so");
force=true
)

# Work around JuliaLang/Pkg.jl#2500
if VERSION < v"1.8-"
test_project = first(Base.load_path())
preferences_file = "LocalPreferences.toml"
test_preferences_file = joinpath(dirname(test_project), "LocalPreferences.toml")
if isfile(preferences_file) && !isfile(test_preferences_file)
cp(preferences_file, test_preferences_file)
end
end
11 changes: 11 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
# Work around JuliaLang/Pkg.jl#2500
if VERSION < v"1.8-"
test_project = first(Base.load_path())
preferences_file = "../LocalPreferences.toml"
test_preferences_file = joinpath(dirname(test_project), "LocalPreferences.toml")
if isfile(preferences_file) && !isfile(test_preferences_file)
cp(preferences_file, test_preferences_file)
@info "copied LocalPreferences.toml to $test_preferences_file"
end
end

using HDF5
using Test
using Pkg
Expand Down

0 comments on commit 1e183f0

Please sign in to comment.