Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,15 @@ DocMeta.setdocmeta!(SpaceExParser, :DocTestSetup,

bib = CitationBibliography(joinpath(@__DIR__, "src", "refs.bib"); style=:alpha)

# Julia parser is broken for `'` in v1.12.0 - v1.12.2
doctest = v"1.12.0" <= VERSION <= v"1.12.2" ? false : true

makedocs(; sitename="SpaceExParser.jl",
modules=[SpaceExParser],
format=Documenter.HTML(; prettyurls=get(ENV, "CI", nothing) == "true",
assets=["assets/aligned.css", "assets/citations.css"]),
pagesonly=true,
doctest=doctest,
plugins=[bib],
pages=["Home" => "index.md",
"Examples" => Any["Introduction" => "examples/examples.md",
Expand Down
7 changes: 5 additions & 2 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
using Test, SpaceExParser, HybridSystems, MathematicalSystems

include("unit_examples.jl")
include("unit_parse.jl")
include("unit_affine.jl")
@static if VERSION < v"1.12.0" || VERSION > v"1.12.2"
# Julia parser is broken for `'` in v1.12.0 - v1.12.2
include("unit_examples.jl")
include("unit_affine.jl")
end

include("Aqua.jl")
2 changes: 1 addition & 1 deletion test/unit_affine.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ using LazySets
AFFINE_SYSTEM = ConstrainedLinearControlContinuousSystem

@testset "Bouncing ball" begin
H = readsxmodel("../examples/bball/bball_flattened.xml"; ST=AFFINE_SYSTEM)
H = readsxmodel(joinpath(@__DIR__, "../examples/bball/bball_flattened.xml"); ST=AFFINE_SYSTEM)

@test nmodes(H) == 1
@test ntransitions(H) == 1
Expand Down
10 changes: 6 additions & 4 deletions test/unit_examples.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@testset "Bouncing ball" begin
H = readsxmodel("../examples/bball/bball_flattened.xml")
H = readsxmodel(joinpath(@__DIR__, "../examples/bball/bball_flattened.xml"))
@test nmodes(H) == 1
@test ntransitions(H) == 1

Expand All @@ -13,7 +13,8 @@
end

@testset "Van der Pol" begin
H = readsxmodel("../examples/van_der_pol_fourth_quadrant/van_der_pol_fourth_quadrant.xml")
H = readsxmodel(joinpath(@__DIR__,
"../examples/van_der_pol_fourth_quadrant/van_der_pol_fourth_quadrant.xml"))
@test nmodes(H) == 1
@test ntransitions(H) == 0

Expand All @@ -23,7 +24,8 @@ end
end

@testset "Lotka-Volterra" begin
H = readsxmodel("../examples/lotka_volterra_fourth_quadrant/lotka_volterra_fourth_quadrant.xml")
H = readsxmodel(joinpath(@__DIR__,
"../examples/lotka_volterra_fourth_quadrant/lotka_volterra_fourth_quadrant.xml"))
@test nmodes(H) == 1
@test ntransitions(H) == 0

Expand All @@ -33,7 +35,7 @@ end
end

@testset "Circle" begin
H = readsxmodel("../examples/circle/circle_flattened.xml")
H = readsxmodel(joinpath(@__DIR__, "../examples/circle/circle_flattened.xml"))
@test nmodes(H) == 2
@test ntransitions(H) == 2
for (i, ti) in enumerate(transitions(H))
Expand Down
Loading