diff --git a/tests/utils.py b/tests/utils.py index 2dbc309aee..25f66f8442 100644 --- a/tests/utils.py +++ b/tests/utils.py @@ -209,7 +209,7 @@ def clean_up_migration_jobs(client, vm): def get_os_cpu_count(vm): if "windows" in vm.name: - cmd = shlex.split("echo %NUMBER_OF_PROCESSORS%") + cmd = shlex.split('powershell.exe -command "[Environment]::ProcessorCount"') else: cmd = shlex.split("nproc") return int(run_ssh_commands(host=vm.ssh_exec, commands=cmd)[0].strip())