Skip to content

Commit

Permalink
Add some tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanaelbosch committed Oct 12, 2023
1 parent 13360f8 commit 83c3813
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
4 changes: 4 additions & 0 deletions test/testbase.jl
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@
@test Kcopy isa AbstractKroneckerProduct

@test similar(K) isa AbstractKroneckerProduct

Kcopy = similar(A) similar(B)
@test_nowarn copy!(Kcopy, K)
@test Kcopy K
end

@testset "Using vectors" begin
Expand Down
6 changes: 5 additions & 1 deletion test/testkroneckersum.jl
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,18 @@

@test issquare(KS)

@test copy(KS) isa KroneckerSum
@test copy(KS) isa KroneckerSum

KScopy = deepcopy(KS)
@test KScopy KS
@test KScopy isa KroneckerSum

@test similar(KS) isa KroneckerSum

KScopy = similar(A) similar(B)
@test_nowarn copy!(KScopy, KS)
@test KScopy KS

IC = oneunit(C)
KS3 = A B C
KS3AB = (A B) C
Expand Down

0 comments on commit 83c3813

Please sign in to comment.