MCPcopy Create free account
hub / github.com/Notgnoshi/generative / test_forward

Method test_forward

tests/test_turtle.py:35–41  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

33 assert_allclose(turtle.rotation.as_matrix(), [expected], atol=1e-15)
34
35 def test_forward(self):
36 turtle = Turtle()
37 assert_allclose(turtle.position, (0, 0, 0))
38 turtle.forward()
39 assert_allclose(turtle.position, (0, 0, 1))
40 turtle.forward(2)
41 assert_allclose(turtle.position, (0, 0, 3))
42
43 def test_rotated_forward(self):
44 # Apparently this rotates CW

Callers

nothing calls this directly

Calls 2

forwardMethod · 0.95
TurtleClass · 0.90

Tested by

no test coverage detected