Add environment variable for faster tests
This commit is contained in:
parent
fb2c2e7429
commit
e01e8e2b55
@ -8,7 +8,12 @@ import PkgTemplates: badges, version_floor, substitute, read_license, gen_file,
|
|||||||
|
|
||||||
mktempdir() do temp_dir
|
mktempdir() do temp_dir
|
||||||
withenv("JULIA_PKGDIR" => temp_dir) do
|
withenv("JULIA_PKGDIR" => temp_dir) do
|
||||||
|
# We technically don't need to clone METADATA to run tests.
|
||||||
|
if get(ENV, "PKGTEMPLATES_TEST_FAST", "false") == "true"
|
||||||
|
mkdir(joinpath(temp_dir, "v$(version_floor())"))
|
||||||
|
else
|
||||||
Pkg.init()
|
Pkg.init()
|
||||||
|
end
|
||||||
cd(temp_dir) do
|
cd(temp_dir) do
|
||||||
@testset "PkgTemplates.jl" begin
|
@testset "PkgTemplates.jl" begin
|
||||||
include("tests.jl")
|
include("tests.jl")
|
||||||
|
Loading…
Reference in New Issue
Block a user