Conditions | 2 |
Total Lines | 7 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | import pytest |
||
42 | @pytest.mark.curio |
||
43 | #@patch('test_bricknil.TrainMotor.set_output', new_callable=AsyncMock) |
||
44 | async def test_motor(self): |
||
45 | m = TrainMotor('motor') |
||
46 | m.set_output = Mock(side_effect=coroutine(lambda x,y :'the awaitable should return this')) |
||
47 | await m.set_speed(10) |
||
48 | assert m.set_output.call_args == call(0, 10) |
||
49 | |||
50 |