test_direct_api.py -> add test for Plane.isometric

This commit is contained in:
jdegenstein 2024-06-24 09:10:06 -05:00 committed by GitHub
parent 33b6859270
commit d0f4fbfa62
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2281,6 +2281,7 @@ class TestPlane(DirectApiTestCase):
right +y +z +x
top +x +y +z
bottom +x -y -z
isometric +x+y -x+y+z +x+y-z
"""
planes = [
(Plane.XY, (1, 0, 0), (0, 0, 1)),
@ -2295,6 +2296,7 @@ class TestPlane(DirectApiTestCase):
(Plane.right, (0, 1, 0), (1, 0, 0)),
(Plane.top, (1, 0, 0), (0, 0, 1)),
(Plane.bottom, (1, 0, 0), (0, 0, -1)),
(Plane.isometric, (1 / 2**0.5, 1 / 2**0.5, 0), (1 / 3**0.5, -1 / 3**0.5, 1 / 3**0.5)),
]
for plane, x_dir, z_dir in planes:
self.assertVectorAlmostEquals(plane.x_dir, x_dir, 5)