Skip to content

Commit

Permalink
Add aqua tests (#329)
Browse files Browse the repository at this point in the history
* Add aqua tests

* Skip some aqua tests on julia 1.9

* Update Project.toml

* Skip ambiguity dev test, rm Project toml test

* Increment patch version
  • Loading branch information
charleskawczynski authored Jun 13, 2023
1 parent d546e3f commit 4f9d799
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 8 deletions.
17 changes: 9 additions & 8 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,30 +1,31 @@
name = "TaylorSeries"
uuid = "6aa5eb33-94cf-58f4-a9d0-e4b2c4fc25ea"
repo = "https://github.com/JuliaDiff/TaylorSeries.jl.git"
version = "0.15.0"
version = "0.15.1"

[deps]
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Markdown = "d6f4376e-aef5-505a-96c1-9c027394607a"
Requires = "ae029012-a4dd-5104-9daa-d747884805df"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"

[weakdeps]
IntervalArithmetic = "d1acc4aa-44c8-5952-acd4-ba5d80a2a253"

[extensions]
TaylorSeriesIAExt = "IntervalArithmetic"

[compat]
IntervalArithmetic = "0.15, 0.16, 0.17, 0.18, 0.19, 0.20"
Requires = "0.5.2, 1"
julia = "1"

[extensions]
TaylorSeriesIAExt = "IntervalArithmetic"

[extras]
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
IntervalArithmetic = "d1acc4aa-44c8-5952-acd4-ba5d80a2a253"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["IntervalArithmetic", "LinearAlgebra", "SparseArrays", "Test"]
test = ["IntervalArithmetic", "LinearAlgebra", "SparseArrays", "Test", "Aqua"]

[weakdeps]
IntervalArithmetic = "d1acc4aa-44c8-5952-acd4-ba5d80a2a253"
30 changes: 30 additions & 0 deletions test/aqua.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
using Test
using TaylorSeries
using Aqua

@testset "Aqua tests (performance)" begin
# This tests that we don't accidentally run into
# https://github.com/JuliaLang/julia/issues/29393
# Aqua.test_unbound_args(TaylorSeries)
ua = Aqua.detect_unbound_args_recursively(TaylorSeries)
@test length(ua) == 0

# See: https://github.com/SciML/OrdinaryDiffEq.jl/issues/1750
# Test that we're not introducing method ambiguities across deps
ambs = Aqua.detect_ambiguities(TaylorSeries; recursive = true)
pkg_match(pkgname, pkdir::Nothing) = false
pkg_match(pkgname, pkdir::AbstractString) = occursin(pkgname, pkdir)
filter!(x -> pkg_match("TaylorSeries", pkgdir(last(x).module)), ambs)
if VERSION < v"1.10.0-DEV"
@test length(ambs) == 0
end
end

@testset "Aqua tests (additional)" begin
Aqua.test_undefined_exports(TaylorSeries)
Aqua.test_deps_compat(TaylorSeries)
Aqua.test_stale_deps(TaylorSeries; ignore=[:Requires])
Aqua.test_piracy(TaylorSeries)
end

nothing
1 change: 1 addition & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
# Tests for TaylorSeries

testfiles = (
"aqua.jl",
"onevariable.jl",
"manyvariables.jl",
"mixtures.jl",
Expand Down

2 comments on commit 4f9d799

@lbenet
Copy link
Member

@lbenet lbenet commented on 4f9d799 Jun 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/85479

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.15.1 -m "<description of version>" 4f9d7993628ca3f818c3209cffb735d256ee524b
git push origin v0.15.1

Please sign in to comment.