1
0
mirror of https://github.com/avatao-content/test-tutorial-framework synced 2024-12-05 02:31:33 +00:00

Implement command to change layout from cli

This commit is contained in:
Kristóf Tóth 2018-04-20 14:42:32 +02:00
parent d6ff80230f
commit 41d6fa7417

View File

@ -43,6 +43,14 @@ class TestCommands(TerminalCommands):
'shellcmd': f'{seppuku}\n'}
})
def command_changelayout(self, *args):
message = {'key': 'dashboard',
'data': {'command': 'layout',
'layout': args[0]}}
if len(args) >= 2:
message['data']['hide_messages'] = (args[1] in ['yes', 'y', '1', 'true'])
TFWServerConnector().send(message)
if __name__ == '__main__':
# pylint: disable=invalid-name