From e3d653a8d963f140f809d711a0ebc903d1d610a9 Mon Sep 17 00:00:00 2001 From: Thomas Breloff Date: Mon, 26 Oct 2015 11:38:33 -0400 Subject: [PATCH] tests --- test/imgcomp.jl | 8 +++++--- test/runtests.jl | 12 +++++++----- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/test/imgcomp.jl b/test/imgcomp.jl index 69c61807..b0d38213 100644 --- a/test/imgcomp.jl +++ b/test/imgcomp.jl @@ -1,11 +1,13 @@ -# include this first to help with crashing?? -using Gtk +# # include this first to help with crashing?? +# using Gtk # don't let pyplot use a gui... it'll crash # note: Agg will set gui -> :none in PyPlot ENV["MPLBACKEND"] = "Agg" -import PyPlot +try + @eval import PyPlot +end # macro test_approx_eq_sigma_eps(A, B, sigma, eps) diff --git a/test/runtests.jl b/test/runtests.jl index 7278a4d4..c2fe3606 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -53,12 +53,14 @@ facts("Gadfly") do end -facts("PyPlot") do - @fact pyplot() --> Plots.PyPlotPackage() - @fact backend() --> Plots.PyPlotPackage() - image_comparison_tests(:pyplot, skip=[19], eps=img_eps) -end +if VERSION >= v"0.4-" + facts("PyPlot") do + @fact pyplot() --> Plots.PyPlotPackage() + @fact backend() --> Plots.PyPlotPackage() + image_comparison_tests(:pyplot, skip=[19], eps=img_eps) + end +end # catch err