Skip to content

Commit

Permalink
tests for vector adjoint/transpose
Browse files Browse the repository at this point in the history
  • Loading branch information
jishnub committed Jun 5, 2023
1 parent 17929ee commit 716ae1e
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1718,9 +1718,21 @@ end
@test A' === OneElement(-3im, (4,2), (6,4))
@test transpose(A) === OneElement(3im, (4,2), (6,4))

A = OneElement(3im, 2, 3)
@test A' isa Adjoint
@test transpose(A) isa Transpose
@test A' == OneElement(-3im, (1,2), (1,3))
@test transpose(A) == OneElement(3im, (1,2), (1,3))

A = OneElement(3, (2,2), (4,4))
@test adjoint(A) === A
@test transpose(A) === A

A = OneElement(3, 2, 4)
@test transpose(A) isa Transpose
@test adjoint(A) isa Adjoint
@test transpose(A) == OneElement(3, (1,2), (1,4))
@test adjoint(A) == OneElement(3, (1,2), (1,4))
end

@testset "matmul" begin
Expand Down

0 comments on commit 716ae1e

Please sign in to comment.