Skip to content

Commit

Permalink
asset
Browse files Browse the repository at this point in the history
  • Loading branch information
penelopeysm committed Sep 8, 2024
1 parent 37b6904 commit 4fa1b97
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 22 deletions.
40 changes: 20 additions & 20 deletions PlotsBase/test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -65,27 +65,27 @@ else
end

for name (
"misc",
"utils",
"args",
"defaults",
"dates",
"axes",
"layouts",
"contours",
"components",
"shorthands",
"recipes",
"unitful",
"hdf5plots",
"pgfplotsx",
"plotly",
"animations",
"output",
# "misc",
# "utils",
# "args",
# "defaults",
# "dates",
# "axes",
# "layouts",
# "contours",
# "components",
# "shorthands",
# "recipes",
# "unitful",
# "hdf5plots",
# "pgfplotsx",
# "plotly",
# "animations",
# "output",
"reference",
"backends",
"preferences",
"quality",
# "backends",
# "preferences",
# "quality",
)
@testset "$name" begin
# skip the majority of tests if we only want to update reference images or under `PkgEval` (timeout limit)
Expand Down
10 changes: 8 additions & 2 deletions PlotsBase/test/test_reference.jl
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,12 @@ function reference_file(backend, version, i)
return reffn
end

function VisualTest2(testFunction::Function, refFilename::AbstractString, args...; kw...)
p = abspath("artifact.png")
@show p
VisualTest(p, testFunction, args, kw, refFilename)
end

function image_comparison_tests(
pkg::Symbol,
idx::Int;
Expand Down Expand Up @@ -97,7 +103,7 @@ function image_comparison_tests(

func = fn -> Base.eval.(Ref(TESTS_MODULE), (imports, exprs, :(png($fn))))
test_images(
VisualTest(func, reffn),
VisualTest2(func, reffn),
newfn = newfn,
popup = popup,
sigma = sigma,
Expand All @@ -115,7 +121,7 @@ function image_comparison_facts(
)
for i setdiff(1:length(PlotsBase._examples), skip)
if only nothing || i in only
if i == 50
if pkg == :gr && i == 50
@test success(image_comparison_tests(pkg, i; debug, sigma, tol))
end
end
Expand Down

0 comments on commit 4fa1b97

Please sign in to comment.