Skip to content

Commit

Permalink
Add doc tests and Aqua tests
Browse files Browse the repository at this point in the history
  • Loading branch information
oschulz committed Aug 5, 2024
1 parent d72e858 commit d2d60ee
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 3 deletions.
5 changes: 2 additions & 3 deletions test/Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
[deps]
PropDicts = "4dc08600-4268-439e-8673-d706fafbb426"
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[compat]
PropDicts = "0.2"
4 changes: 4 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ using LegendTestData
using PropDicts
using Test

include("test_aqua.jl")

@testset "Package LegendTestData" begin

@info legend_test_data_path()
Expand Down Expand Up @@ -40,3 +42,5 @@ using Test
@test isfile(ENV["LEGEND_DATA_CONFIG"])
end
end # testset

include("test_docs.jl")
16 changes: 16 additions & 0 deletions test/test_aqua.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# This file is a part of LegendTestData.jl, licensed under the MIT License (MIT).

import Test
import Aqua
import LegendTestData

Test.@testset "Package ambiguities" begin
Test.@test isempty(Test.detect_ambiguities(LegendTestData))
end # testset

Test.@testset "Aqua tests" begin
Aqua.test_all(
LegendTestData,
ambiguities = true
)
end # testset
13 changes: 13 additions & 0 deletions test/test_docs.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# This file is a part of LegendTestData.jl, licensed under the MIT License (MIT).

using Test
using LegendTestData
import Documenter

Documenter.DocMeta.setdocmeta!(
LegendTestData,
:DocTestSetup,
:(using LegendTestData);
recursive=true,
)
Documenter.doctest(LegendTestData)

0 comments on commit d2d60ee

Please sign in to comment.