MCPcopy Create free account
hub / github.com/20tab/UnrealEnginePython / TestTransform

Class TestTransform

tests.py:19–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17tester_actor = None
18
19class TestTransform(unittest.TestCase):
20 def setUp(self):
21 self.actor = tests.tester_actor
22
23 def test_location(self):
24 self.actor.set_actor_location(1, 1, 1)
25 location = self.actor.get_actor_location()
26 self.assertEqual(location, (1, 1, 1))
27
28 def test_rotation(self):
29 self.actor.set_actor_rotation(17, 22, 30)
30 roll, pitch, yaw = self.actor.get_actor_rotation()
31 self.assertTrue(17 - roll < 0.01)
32 self.assertTrue(22 - pitch < 0.01)
33 self.assertTrue(30 - yaw < 0.01)
34
35 def test_scale(self):
36 self.actor.set_actor_scale(3, 5, 7)
37 scale = self.actor.get_actor_scale()
38 self.assertEqual(scale, (3, 5, 7))
39
40class TestPlayer(unittest.TestCase):
41 def setUp(self):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected