Skip to content

Commit

Permalink
Merge pull request #2595 from JuliaReach/schillic/2139
Browse files Browse the repository at this point in the history
#2139 - Do not depend on Plots.jl for testing
  • Loading branch information
schillic authored Feb 26, 2021
2 parents 412eab1 + 9f9f1b7 commit e1c2ffa
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 20 deletions.
5 changes: 2 additions & 3 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ MathProgBase = "0.7"
MiniQhull = "0.1, 0.2"
ModelingToolkit = "0.8.0, 1.1.3, 4.5, ~5.0, ~5.1"
Optim = "0.15, 0.16, 0.17, 0.18, 0.19, 0.20, 0.21, 0.22, 1.0"
Plots = "0.25, 0.26, 0.27, 0.28, 0.29, 1.0"
Polyhedra = "0.6"
RecipesBase = "0.6, 0.7, 0.8, 1.0"
Reexport = "0.2, 1.0"
Expand All @@ -56,11 +55,11 @@ Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a"
MiniQhull = "978d7f02-9e05-4691-894f-ae31a51d76ca"
ModelingToolkit = "961ee093-0014-501f-94e3-6117800e7a78"
Optim = "429524aa-4258-5aef-a3af-852621145aeb"
Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"
Polyhedra = "67491407-f73d-577b-9b50-8179a7c68029"
RecipesBase = "3cdcf5f2-1ef4-517c-9805-6587b60abb01"
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
TaylorModels = "314ce334-5f6e-57ae-acf6-00b6e903104a"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["CDDLib", "Distributions", "Documenter", "Expokit", "GR", "IntervalConstraintProgramming", "IntervalMatrices", "Makie", "ModelingToolkit", "Optim", "Plots", "Polyhedra", "StaticArrays", "TaylorModels", "Test"]
test = ["CDDLib", "Distributions", "Documenter", "Expokit", "GR", "IntervalConstraintProgramming", "IntervalMatrices", "Makie", "ModelingToolkit", "Optim", "Polyhedra", "RecipesBase", "StaticArrays", "TaylorModels", "Test"]
10 changes: 0 additions & 10 deletions src/ConcreteOperations/convex_hull.jl
Original file line number Diff line number Diff line change
Expand Up @@ -131,16 +131,6 @@ julia> hull = convex_hull(points);
julia> typeof(hull)
Array{Array{Float64,1},1}
```
Plot both the random points and the computed convex hull polygon:
```jldoctest ch_label
julia> using Plots;
julia> plot([Tuple(pi) for pi in points], seriestype=:scatter);
julia> plot!(VPolygon(hull), alpha=0.2);
```
"""
function convex_hull(points::Vector{VN};
algorithm=nothing,
Expand Down
18 changes: 11 additions & 7 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -177,13 +177,17 @@ if test_suite_basic
end

if test_suite_plotting
import Plots
using Plots: plot

# fix namespace conflicts with Plots
using LazySets: center, translate

@time @testset "LazySets.plotting" begin include("unit_plot.jl") end
@static if VERSION >= v"1.1"
# define `plot` function as `RecipesBase.apply_recipe`
import RecipesBase
struct DummyBackend <: RecipesBase.AbstractBackend end
struct DummyPlot <: RecipesBase.AbstractPlot{DummyBackend} end
Base.length(::DummyPlot) = 0
dict = Dict{Symbol, Any}(:plot_object => DummyPlot())
plot(args...; kwargs...) = RecipesBase.apply_recipe(dict, args...; kwargs...)

@time @testset "LazySets.plotting" begin include("unit_plot.jl") end
end
end

if test_suite_doctests
Expand Down

0 comments on commit e1c2ffa

Please sign in to comment.