From 9d7052d55781d4553f8c22b7cb3aad8e9f4f4721 Mon Sep 17 00:00:00 2001 From: Andy Zhang <37402126+AnzhiZhang@users.noreply.github.com> Date: Thu, 8 Aug 2024 17:49:31 +0100 Subject: [PATCH] test(matrices): add cauchy tests --- test/matrices/fiedler.jl | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 test/matrices/fiedler.jl diff --git a/test/matrices/fiedler.jl b/test/matrices/fiedler.jl new file mode 100644 index 0000000..854fca9 --- /dev/null +++ b/test/matrices/fiedler.jl @@ -0,0 +1,15 @@ +# constructors +@test allequal([ + Fiedler(5), + Fiedler{Int}(5), + Fiedler([1:5;]), +]) + +# linear algebra functions +test_linearalgrbra_functions(Fiedler.(1:5)) + +# eltype +@test test_matrix_elements(Fiedler{Int32}(5)) + +# content +@test Fiedler(5) ≈ [0 1 2 3 4; 1 0 1 2 3; 2 1 0 1 2; 3 2 1 0 1; 4 3 2 1 0]