Re: [PATCH] Add support for python2.4 virtio_console.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2010-11-26 at 10:58 +0100, Lukas Doktor wrote:
> From: JiÅÃ Åupka <jzupka@xxxxxxxxxx>


I actually made this patch myself on the v2 I sent to the mailing list
and applied after it. But thanks anyway :)

Lucas

> ---
>  client/tests/kvm/tests/virtio_console.py |   16 +++++++++++-----
>  1 files changed, 11 insertions(+), 5 deletions(-)
> 
> diff --git a/client/tests/kvm/tests/virtio_console.py b/client/tests/kvm/tests/virtio_console.py
> index d69c0a5..3edd051 100644
> --- a/client/tests/kvm/tests/virtio_console.py
> +++ b/client/tests/kvm/tests/virtio_console.py
> @@ -102,7 +102,9 @@ def run_virtio_console(test, params, env):
>              """
>              @return: If any of subtest not pass return True.
>              """
> -            return True if self.failed > 0 else False
> +            if self.failed > 0:
> +                return True
> +            return False
>  
>          def get_result(self):
>              """
> @@ -121,16 +123,20 @@ def run_virtio_console(test, params, env):
>              for arg in result[2]:
>                  sargs += str(arg) + ","
>              sargs = sargs[:-1]
> -            return ("Subtest (%s(%s)):  -->%s") % (result[1], sargs,
> -                                             "PASS"if result[0] else "FAIL")
> +            res = "FAIL"
> +            if result[0]:
> +                res = "PASS"
> +            return ("Subtest (%s(%s)):  -->%s") % (result[1], sargs,res)
>  
> 
>          def result_to_string(self, result):
>              """
>              @param result: Result of test.
>              """
> -            return ("Subtest (%s):  -->%s") % (result[1], "PASS"if result[0]
> -                                                               else "FAIL")
> +            res = "FAIL"
> +            if result[0]:
> +                res = "PASS"
> +            return ("Subtest (%s):  -->%s") % (result[1], res)
>  
> 
>          def get_full_text_result(self):


--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux