We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 416e559 commit a527e14Copy full SHA for a527e14
1 file changed
src/python_pybind11/test/Matrix3_TEST.py
@@ -307,7 +307,9 @@ def test_to_quaternion(self):
307
q = Quaterniond(math.pi/2.0, math.pi/2.0, 0)
308
matFromQuat = Matrix3d(q)
309
quatFromMat = Quaterniond(matFromQuat)
310
- self.assertTrue(q == quatFromMat)
+ # We check both cases as quaternion double-cover the rotation matrix
311
+ # space, see https://github.com/gazebosim/gz-math/issues/416#issuecomment-1741741183
312
+ self.assertTrue(q == quatFromMat or q == -quatFromMat)
313
314
# test the cases where matrix trace is negative
315
# (requires special handling)
0 commit comments