Skip to content

Commit 403c2c2

Browse files
committed
🚨 Improve test coverage in CRP and MRP construction
1 parent 37d80d7 commit 403c2c2

2 files changed

Lines changed: 24 additions & 0 deletions

File tree

test/crp.jl

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,18 @@
1515
@test c.q3 == 3.0
1616
@test eltype(c) == Float64
1717

18+
c = CRP(1.0, 2, 3)
19+
@test c.q1 == 1.0
20+
@test c.q2 == 2.0
21+
@test c.q3 == 3.0
22+
@test eltype(c) == Float64
23+
24+
c = CRP(1.0f0, 2, 3)
25+
@test c.q1 == 1.0
26+
@test c.q2 == 2.0
27+
@test c.q3 == 3.0
28+
@test eltype(c) == Float32
29+
1830
c = CRP(1, 2, 3)
1931
@test c.q1 == 1
2032
@test c.q2 == 2

test/mrp.jl

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,18 @@
1515
@test m.q3 == 3.0
1616
@test eltype(m) == Float64
1717

18+
m = MRP(1.0, 2, 3)
19+
@test m.q1 == 1.0
20+
@test m.q2 == 2.0
21+
@test m.q3 == 3.0
22+
@test eltype(m) == Float64
23+
24+
m = MRP(1.0f0, 2, 3)
25+
@test m.q1 == 1.0
26+
@test m.q2 == 2.0
27+
@test m.q3 == 3.0
28+
@test eltype(m) == Float32
29+
1830
m = MRP(1, 2, 3)
1931
@test m.q1 == 1
2032
@test m.q2 == 2

0 commit comments

Comments
 (0)