Skip to content

Commit abe0ca6

Browse files
authored
Merge pull request #91 from JuliaReach/schillic/test_sa
Test `StaticArrays` code
2 parents 67ba5e4 + 593428f commit abe0ca6

File tree

4 files changed

+15
-0
lines changed

4 files changed

+15
-0
lines changed

test/Arrays/matrix_operations.jl

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
using StaticArrays: SVector, SMatrix
2+
3+
P = projection_matrix([1, 2], 5, SVector{3, Int})
4+
@test P == [1 0 0 0 0; 0 1 0 0 0] && P isa SMatrix{2, 5, Int, 10}
+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
using StaticArrays: SVector
2+
3+
@test similar_type(SVector(1)) == SVector{1, Int}

test/Project.toml

+2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@ Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
44
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
55
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
66
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
7+
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
78
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
89

910
[compat]
1011
Aqua = "0.8"
1112
Documenter = "0.27, 1"
13+
StaticArrays = "1"

test/runtests.jl

+6
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,12 @@ seed!(1234) # fix RNG seed for reproducibility
1414
@testset "logarithmic_norm" begin
1515
include("Arrays/logarithmic_norm.jl")
1616
end
17+
@testset "matrix_operations" begin
18+
include("Arrays/matrix_operations.jl")
19+
end
20+
@testset "matrix_vector_operations" begin
21+
include("Arrays/matrix_vector_operations.jl")
22+
end
1723
@testset "vector_operations" begin
1824
include("Arrays/vector_operations.jl")
1925
end

0 commit comments

Comments
 (0)