Skip to content

Commit b2df755

Browse files
Copilotyebai
andcommitted
Add Aqua tests for automated quality assurance
Co-authored-by: yebai <[email protected]>
1 parent 73f7114 commit b2df755

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed

test/Aqua.jl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
module AquaTests
2+
3+
using Aqua: Aqua
4+
using AbstractPPL
5+
6+
# For now, we skip ambiguities since they come from interactions
7+
# with third-party packages rather than issues in AbstractPPL itself
8+
Aqua.test_all(AbstractPPL; ambiguities=false)
9+
10+
end

test/Project.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
[deps]
22
Accessors = "7d9f7c33-5ae7-4f3b-8dc6-eff91059b697"
3+
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
34
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
45
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
56
InvertedIndices = "41ab1584-1d38-5bbf-9106-f11c6c58b48f"
@@ -10,6 +11,7 @@ Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
1011

1112
[compat]
1213
Accessors = "0.1"
14+
Aqua = "0.8"
1315
Documenter = "0.26.3, 0.27, 1"
1416
InvertedIndices = "1"
1517
OffsetArrays = "1"

test/runtests.jl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,13 @@ using Documenter
33
using Test
44

55
const GROUP = get(ENV, "GROUP", "All")
6+
const AQUA = get(ENV, "AQUA", "true") == "true"
67

78
@testset "AbstractPPL.jl" begin
89
if GROUP == "All" || GROUP == "Tests"
10+
if AQUA
11+
include("Aqua.jl")
12+
end
913
include("varname.jl")
1014
include("abstractprobprog.jl")
1115
include("hasvalue.jl")

0 commit comments

Comments
 (0)