diff options
Diffstat (limited to 'lib/python/qmk/tests/test_cli_commands.py')
-rw-r--r-- | lib/python/qmk/tests/test_cli_commands.py | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/lib/python/qmk/tests/test_cli_commands.py b/lib/python/qmk/tests/test_cli_commands.py index 7ac0bcbde..7c261db6c 100644 --- a/lib/python/qmk/tests/test_cli_commands.py +++ b/lib/python/qmk/tests/test_cli_commands.py | |||
@@ -1,7 +1,11 @@ | |||
1 | import platform | ||
2 | |||
1 | from subprocess import STDOUT, PIPE | 3 | from subprocess import STDOUT, PIPE |
2 | 4 | ||
3 | from qmk.commands import run | 5 | from qmk.commands import run |
4 | 6 | ||
7 | is_windows = 'windows' in platform.platform().lower() | ||
8 | |||
5 | 9 | ||
6 | def check_subcommand(command, *args): | 10 | def check_subcommand(command, *args): |
7 | cmd = ['bin/qmk', command] + list(args) | 11 | cmd = ['bin/qmk', command] + list(args) |
@@ -148,7 +152,11 @@ def test_info_keymap_render(): | |||
148 | check_returncode(result) | 152 | check_returncode(result) |
149 | assert 'Keyboard Name: handwired/onekey/pytest' in result.stdout | 153 | assert 'Keyboard Name: handwired/onekey/pytest' in result.stdout |
150 | assert 'Processor: STM32F303' in result.stdout | 154 | assert 'Processor: STM32F303' in result.stdout |
151 | assert '│A │' in result.stdout | 155 | |
156 | if is_windows: | ||
157 | assert '|A |' in result.stdout | ||
158 | else: | ||
159 | assert '│A │' in result.stdout | ||
152 | 160 | ||
153 | 161 | ||
154 | def test_info_matrix_render(): | 162 | def test_info_matrix_render(): |
@@ -157,7 +165,12 @@ def test_info_matrix_render(): | |||
157 | assert 'Keyboard Name: handwired/onekey/pytest' in result.stdout | 165 | assert 'Keyboard Name: handwired/onekey/pytest' in result.stdout |
158 | assert 'Processor: STM32F303' in result.stdout | 166 | assert 'Processor: STM32F303' in result.stdout |
159 | assert 'LAYOUT_ortho_1x1' in result.stdout | 167 | assert 'LAYOUT_ortho_1x1' in result.stdout |
160 | assert '│0A│' in result.stdout | 168 | |
169 | if is_windows: | ||
170 | assert '|0A|' in result.stdout | ||
171 | else: | ||
172 | assert '│0A│' in result.stdout | ||
173 | |||
161 | assert 'Matrix for "LAYOUT_ortho_1x1"' in result.stdout | 174 | assert 'Matrix for "LAYOUT_ortho_1x1"' in result.stdout |
162 | 175 | ||
163 | 176 | ||