Skip to content

Commit

Permalink
Add tests with Aqua.jl (#160)
Browse files Browse the repository at this point in the history
* add tests with Aqua.jl

* fix compat table

* specify Julia version for test with Aqua.jl
  • Loading branch information
hyrodium authored Oct 20, 2023
1 parent b88f8cb commit 5d227d4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,16 @@ Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
IntervalSetsStatisticsExt = "Statistics"

[compat]
Aqua = "0.7"
julia = "1.6"

[extras]
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
OffsetArrays = "6fe1bfb0-de20-5000-8ca7-80f57d26f881"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d"

[targets]
test = ["Test", "Random", "OffsetArrays", "Statistics", "Unitful"]
test = ["Aqua", "Test", "Random", "OffsetArrays", "Statistics", "Unitful"]
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Interval Sets for Julia
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://JuliaMath.github.io/IntervalSets.jl/dev)
[![Build Status](https://github.com/JuliaMath/IntervalSets.jl/workflows/CI/badge.svg)](https://github.com/JuliaMath/IntervalSets.jl/actions)
[![Coverage](https://codecov.io/gh/JuliaMath/IntervalSets.jl/branch/master/graph/badge.svg)](https://codecov.io/gh/JuliaMath/IntervalSets.jl)
[![Aqua QA](https://raw.githubusercontent.com/JuliaTesting/Aqua.jl/master/badge.svg)](https://github.com/JuliaTesting/Aqua.jl)

This package represents intervals of an ordered set. For an interval
spanning from `a` to `b`, all values `x` that lie between `a` and `b`
Expand Down
6 changes: 6 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ using Unitful

import IntervalSets: Domain, endpoints, closedendpoints, TypedEndpointsInterval

using Aqua
if VERSION v"1.7.0-"
# The verison specification can be removed when https://github.com/JuliaTesting/Aqua.jl/issues/208 is resolved.
Aqua.test_all(IntervalSets)
end

struct MyClosedUnitInterval <: TypedEndpointsInterval{:closed,:closed,Int} end
endpoints(::MyClosedUnitInterval) = (0,1)
Base.promote_rule(::Type{MyClosedUnitInterval}, ::Type{ClosedInterval{T}}) where T =
Expand Down

0 comments on commit 5d227d4

Please sign in to comment.