Skip to content

Commit 89cd598

Browse files
committed
Remove motor destructor before running motor test
So that the fake tree stays intact and git stays clean
1 parent ef92615 commit 89cd598

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/api_tests.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,12 @@ def test_device(self):
2828
self.assertTrue(d.connected)
2929

3030
def test_medium_motor(self):
31+
def dummy(self):
32+
pass
33+
34+
# Do not write motor.command on exit (so that fake tree stays intact)
35+
ev3.MediumMotor.__del__ = dummy
36+
3137
m = ev3.MediumMotor()
3238

3339
self.assertTrue(m.connected);

0 commit comments

Comments
 (0)