(self)
| 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 |