Skip to content

Commit cc4c453

Browse files
authored
test: add DispatchDoctor (no type-stability) (#15)
1 parent f09a6aa commit cc4c453

File tree

3 files changed

+25
-22
lines changed

3 files changed

+25
-22
lines changed

Project.toml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,22 @@ authors = ["Orjan Ameye <[email protected]>"]
44
version = "0.1.0"
55

66
[deps]
7+
DispatchDoctor = "8d63f2c5-f18a-4cf2-ba9d-b3f60fc568c8"
78
DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
89
LaTeXStrings = "b964fa9f-0449-5b57-a5c2-d3ea65f4040f"
910

1011
[compat]
1112
Aqua = "0.8.11"
1213
CheckConcreteStructs = "0.1"
13-
Documenter = "1.11"
14+
DispatchDoctor = "0.4.19"
1415
DocStringExtensions = "0.9.4"
16+
Documenter = "1.11"
1517
ExplicitImports = "1.11"
1618
JET = "0.9.18, 0.10"
1719
LaTeXStrings = "1.4"
1820
Test = "1.10"
1921
julia = "1.10"
22+
Preferences = "1"
2023

2124
[extras]
2225
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
@@ -25,6 +28,7 @@ Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
2528
ExplicitImports = "7d51a73a-1435-4ff3-83d9-f097790105c7"
2629
JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b"
2730
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
31+
Preferences = "21216c6a-2e73-6563-6e65-726566657250"
2832

2933
[targets]
30-
test = ["JET", "CheckConcreteStructs", "ExplicitImports", "Test", "Aqua", "Documenter"]
34+
test = ["JET", "CheckConcreteStructs", "ExplicitImports", "Test", "Aqua", "Documenter", "Preferences"]

src/VanVleckRecursion.jl

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,21 @@
22
$(DocStringExtensions.README)
33
"""
44
module VanVleckRecursion
5+
using DispatchDoctor: @stable
6+
@stable default_mode = "disable" begin
7+
using DocStringExtensions: DocStringExtensions
8+
using LaTeXStrings: LaTeXStrings
59

6-
using DocStringExtensions: DocStringExtensions
7-
using LaTeXStrings: LaTeXStrings
8-
9-
# Export Kamiltonian and Generator functions
10-
export K, S, kamiltonian_get, generator_get, set_hamiltonian!, clear_caches!, latex
11-
export Terms, Term
12-
13-
include("types.jl")
14-
include("operations.jl")
15-
include("comparison.jl")
16-
include("collections.jl")
17-
include("arithmetic.jl")
18-
include("display.jl")
19-
include("kamiltonian.jl")
10+
# Export Kamiltonian and Generator functions
11+
export K, S, kamiltonian_get, generator_get, set_hamiltonian!, clear_caches!, latex
12+
export Terms, Term
2013

14+
include("types.jl")
15+
include("operations.jl")
16+
include("comparison.jl")
17+
include("collections.jl")
18+
include("arithmetic.jl")
19+
include("display.jl")
20+
include("kamiltonian.jl")
21+
end
2122
end # module VanVleckRecursion

test/runtests.jl

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,3 @@
1-
"""
2-
Test suite for VanVleckRecursion.jl
3-
4-
This test suite verifies the functionality of the Van Vleck recursion implementation.
5-
"""
6-
71
using Test
82
using VanVleckRecursion
93

@@ -44,6 +38,10 @@ end
4438
all_concrete(VVR.Terms)
4539
end
4640

41+
using Preferences: set_preferences!
42+
43+
set_preferences!("VanVleckRecursion", "dispatch_doctor_mode" => "error")
44+
4745
# Include all test files
4846
include("types.jl")
4947
include("operations.jl")

0 commit comments

Comments
 (0)