1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-25 06:23:53 +01:00

dist/pythonlibs/riotctrl_shell/tests/common: add expect to mock

This commit is contained in:
Francisco Molina 2021-10-18 15:50:54 +02:00
parent afde4b0e43
commit 3aa6492016

View File

@ -14,6 +14,7 @@ class MockSpawn():
# set some expected attributes
self.before = None
self.echo = False
self.expect_res = 0
@property
def last_command(self):
@ -42,6 +43,9 @@ class MockSpawn():
# always match on prompt with replwrap
return 0
def expect(self, *args, **kwargs):
return self.expect_res
class MockRIOTCtrl():
"""