----- "Amos Kong" <[email protected]> wrote:

> Use 'status_test_command' to decide if it's Windows.
> 
> Signed-off-by: Amos Kong <[email protected]>
> ---
>  0 files changed, 0 insertions(+), 0 deletions(-)
> 
> diff --git a/client/tests/kvm/tests/guest_test.py
> b/client/tests/kvm/tests/guest_test.py
> index b6bebc7..af77e47 100644
> --- a/client/tests/kvm/tests/guest_test.py
> +++ b/client/tests/kvm/tests/guest_test.py
> @@ -63,7 +63,9 @@ def run_guest_test(test, params, env):
>              script_path = kvm_utils.get_path(test.bindir, script)
>              vm.copy_files_to(script_path, dst_rsc_path, timeout=60)
>  
> -        command = "cmd /c %s %s %s" %(interpreter, dst_rsc_path,
> script_params)
> +        command = "%s %s %s" %(interpreter, dst_rsc_path,
> script_params)
> +        if params.get("status_test_command") != "echo $?":
> +            command = "cmd /c %s" % command

A better solution for this is to put "cmd /c" into command itself which may let
the kind of guest transparent to guest_test.

>  
>          logging.info("---------------- Script output
> ----------------")
>          status = session.get_command_status(command,
_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

Reply via email to