From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33585) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBdEc-0006xn-M8 for qemu-devel@nongnu.org; Thu, 15 Jan 2015 00:44:47 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YBdEZ-0006Lp-G2 for qemu-devel@nongnu.org; Thu, 15 Jan 2015 00:44:46 -0500 Received: from mx1.redhat.com ([209.132.183.28]:45951) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBdEZ-0006Lj-8O for qemu-devel@nongnu.org; Thu, 15 Jan 2015 00:44:43 -0500 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t0F5ifot006929 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Thu, 15 Jan 2015 00:44:42 -0500 From: Fam Zheng Date: Thu, 15 Jan 2015 13:44:34 +0800 Message-Id: <1421300674-18659-1-git-send-email-famz@redhat.com> Subject: [Qemu-devel] [PATCH] qemu-iotests: Fix supported_oses check List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Kevin Wolf , Stefan Hajnoczi There is a bug in the recently added sys.platform test and we no longer run python tests, because "linux2" is the value to compare here. So do a prefix match, although the python documentation claims Linux is always linux2. Signed-off-by: Fam Zheng --- tests/qemu-iotests/iotests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index 87002e0..4011725 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -288,7 +288,7 @@ def main(supported_fmts=[], supported_oses=['linux']): if supported_fmts and (imgfmt not in supported_fmts): notrun('not suitable for this image format: %s' % imgfmt) - if sys.platform not in supported_oses: + if not any([sys.platform.startswith(x) for x in supported_oses]): notrun('not suitable for this OS: %s' % sys.platform) # We need to filter out the time taken from the output so that qemu-iotest -- 1.9.3