File tree 1 file changed +9
-10
lines changed
pytest-embedded-wokwi/pytest_embedded_wokwi 1 file changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -57,22 +57,21 @@ def __init__(
57
57
58
58
# first need to check if wokwi-cli exists in PATH
59
59
if shutil .which ('wokwi-cli' ) is None :
60
- print ('Please install wokwi-cli, by running: curl -L https://wokwi.com/ci/install.sh | sh' )
61
- # self.install_wokwi() not implemented yet
60
+ raise RuntimeError ('Please install wokwi-cli, by running: curl -L https://wokwi.com/ci/install.sh | sh' )
62
61
63
62
child = pexpect .spawn ('wokwi-cli --help' )
64
63
try :
65
64
child .expect (r'Wokwi CLI v(\d+\.\d+\.\d+)' , timeout = 1 )
66
65
wokwi_cli_version = child .match .group (1 ).decode ('utf-8' )
67
66
except pexpect .TIMEOUT :
68
- raise RuntimeError ('Failed to run wokwi-cli' )
69
-
70
- if Version (wokwi_cli_version ) < Version (WOKWI_CLI_MINIMUM_VERSION ):
71
- raise ValueError (
72
- f'Wokwi CLI version { wokwi_cli_version } is not supported. '
73
- f'Minimum version required: { WOKWI_CLI_MINIMUM_VERSION } . '
74
- f'To update Wokwi CLI run: curl -L https://wokwi.com/ci/install.sh | sh'
75
- )
67
+ logging . warning ('Failed to get wokwi-cli version, assume version requirements satisfied ' )
68
+ else :
69
+ if Version (wokwi_cli_version ) < Version (WOKWI_CLI_MINIMUM_VERSION ):
70
+ raise ValueError (
71
+ f'Wokwi CLI version { wokwi_cli_version } is not supported. '
72
+ f'Minimum version required: { WOKWI_CLI_MINIMUM_VERSION } . '
73
+ f'To update Wokwi CLI run: curl -L https://wokwi.com/ci/install.sh | sh'
74
+ )
76
75
77
76
self .create_wokwi_toml ()
78
77
You can’t perform that action at this time.
0 commit comments