Skip to content

Commit

Permalink
Fix randomly failing log test on nightly (#116)
Browse files Browse the repository at this point in the history
* Fix randomly failing log test on nightly

* Update test/Quaternion.jl

Co-authored-by: Yuto Horikawa <hyrodium@gmail.com>

Co-authored-by: Yuto Horikawa <hyrodium@gmail.com>
  • Loading branch information
sethaxen and hyrodium authored Dec 7, 2022
1 parent 0f57093 commit e46a689
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/Quaternion.jl
Original file line number Diff line number Diff line change
Expand Up @@ -379,10 +379,10 @@ end
@testset "log" begin
@test log(zero(QuaternionF64)) === Quaternion(-Inf, 0, 0, 0)
@test log(one(QuaternionF64)) === Quaternion(0.0, 0, 0, 0)
@test log(-one(QuaternionF64)) == Quaternion(0.0, π, 0, 0)
@test log(-one(QuaternionF64)) Quaternion(0, π, 0, 0)
x = rand()
@test log(quat(x)) == quat(log(x))
@test log(quat(-x)) == Quaternion(reim(log(complex(-x)))..., 0, 0)
@test log(quat(x)) quat(log(x))
@test log(quat(-x)) Quaternion(reim(log(complex(-x)))..., 0, 0)
end

@testset "exp" begin
Expand Down

0 comments on commit e46a689

Please sign in to comment.