Skip to content

Commit

Permalink
Add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jishnub committed Sep 14, 2020
1 parent fd542d8 commit 8db31b0
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -966,9 +966,12 @@ end
@test axes(ones(2, 2:3) * ones(2:3)) == (1:2,)

# One-based arrays
oa2 = OffsetArray(a, (0, 0))
@test parent(oa2 * a) == a * a
@test parent(a * oa2) == a * a
oa2 = OffsetArray(a, axes(a))
@test oa2 * a == a * a
@test a * oa2 == a * a

@test oa2 * v == a * v
@test v' * oa2 == v' * a

@test_throws Exception zeros(2, 2:3) * zeros(2:4, 2)
@test_throws Exception zeros(2, 2:3) * zeros(3:4, 2)
Expand Down

0 comments on commit 8db31b0

Please sign in to comment.