@@ -2056,14 +2056,16 @@ def mock_get_url(url: str, *args, **kwargs) -> str:
2056
2056
assert expect_out .match (err ), err
2057
2057
2058
2058
2059
+ @pytest .mark .enable_socket
2059
2060
@pytest .mark .parametrize (
2060
2061
"cmd, arch_dict, details, expected_command" ,
2061
2062
[
2062
2063
(
2063
- "install-qt-commercial desktop {} 6.8.0 " "--outputdir . /install-qt-commercial " "--user {} --password {}" ,
2064
+ "install-qt-commercial desktop {} 6.8.0 " "--outputdir /tmp /install-qt-commercial " "--user {} --password {}" ,
2064
2065
{"windows" : "win64_msvc2022_64" , "linux" : "linux_gcc_64" , "mac" : "clang_64" },
2065
- ["./install-qt-commercial" , "qt6" , "681" ],
2066
- "qt-unified-{}-online.run --email ******** --pw ******** --root {} --accept-licenses --accept-obligations "
2066
+ ["/tmp/install-qt-commercial" , "qt6" , "680" ],
2067
+ "qt-unified-{}-x64-online.run --email ******** --pw ******** --root {} "
2068
+ "--accept-licenses --accept-obligations "
2067
2069
"--confirm-command "
2068
2070
"--auto-answer OperationDoesNotExistError=Ignore,OverwriteTargetDirectory=No,"
2069
2071
"stopProcessesForUpdates=Cancel,installationErrorWithCancel=Cancel,installationErrorWithIgnore=Ignore,"
@@ -2079,12 +2081,12 @@ def test_install_qt_commercial(
2079
2081
arch = arch_dict [current_platform ]
2080
2082
2081
2083
formatted_cmd = cmd .
format (
arch ,
"[email protected] " ,
"WxK43TdWCTmxsrrpnsWbjPfPXVq3mtLK" )
2082
- formatted_expected = expected_command .format (arch , * details , arch )
2084
+ formatted_expected = expected_command .format (current_platform , * details , arch )
2083
2085
2084
2086
cli = Cli ()
2085
2087
cli ._setup_settings ()
2086
2088
2087
2089
cli .run (formatted_cmd .split ())
2088
2090
2089
- [ out , _ ] = capsys .readouterr ()
2090
- assert str (out ).find (formatted_expected )
2091
+ out = " " . join ( capsys .readouterr () )
2092
+ assert str (out ).find (formatted_expected ) >= 0
0 commit comments