From patchwork Mon Dec 2 10:10:34 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Huth X-Patchwork-Id: 1203042 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org (client-ip=209.51.188.17; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.b="S3ws1Z6g"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 47RLVw0VDWz9sPh for ; Mon, 2 Dec 2019 21:11:36 +1100 (AEDT) Received: from localhost ([::1]:33290 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ibig1-0001pX-L2 for incoming@patchwork.ozlabs.org; Mon, 02 Dec 2019 05:11:33 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:59996) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ibifO-0001Zv-9S for qemu-devel@nongnu.org; Mon, 02 Dec 2019 05:10:55 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ibifM-0004sM-QC for qemu-devel@nongnu.org; Mon, 02 Dec 2019 05:10:54 -0500 Received: from us-smtp-1.mimecast.com ([205.139.110.61]:23924 helo=us-smtp-delivery-1.mimecast.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ibifM-0004s4-M2 for qemu-devel@nongnu.org; Mon, 02 Dec 2019 05:10:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1575281452; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=LW9vfVfP6WQf/BBc/u6uwPPW40eTp/44+B947kMH/G0=; b=S3ws1Z6ghmo1aToTk+K5IGvuLbwXqnVAYaesn5p9IzfVXQy7Q1DYxTZt1pwo/BA/wP4laG 8FrVqmaxLgFYlL89cMmAGpm+ZIykzIq5BudIRhssZEiciDjTckKa9EJeQv6edJ+lojS3jV j8Ked9kpDQwxGts0IPMV4voGCrI08RI= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-266-n4ZoMZHpNYaOFIYiC3aG8A-1; Mon, 02 Dec 2019 05:10:49 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id B1B8C800EB7; Mon, 2 Dec 2019 10:10:48 +0000 (UTC) Received: from thuth.com (ovpn-117-196.ams2.redhat.com [10.36.117.196]) by smtp.corp.redhat.com (Postfix) with ESMTP id 59DBC19C68; Mon, 2 Dec 2019 10:10:47 +0000 (UTC) From: Thomas Huth To: qemu-block@nongnu.org, Kevin Wolf , Max Reitz Subject: [PATCH v4 1/6] iotests: remove 'linux' from default supported platforms Date: Mon, 2 Dec 2019 11:10:34 +0100 Message-Id: <20191202101039.8981-2-thuth@redhat.com> In-Reply-To: <20191202101039.8981-1-thuth@redhat.com> References: <20191202101039.8981-1-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-MC-Unique: n4ZoMZHpNYaOFIYiC3aG8A-1 X-Mimecast-Spam-Score: 0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 205.139.110.61 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: John Snow , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" From: John Snow verify_platform will check an explicit whitelist and blacklist instead. The default will now be assumed to be allowed to run anywhere. For tests that do not specify their platforms explicitly, this has the effect of enabling these tests on non-linux platforms. For tests that always specified linux explicitly, there is no change. For Python tests on FreeBSD at least; only seven python tests fail: 045 147 149 169 194 199 211 045 and 149 appear to be misconfigurations, 147 and 194 are the AF_UNIX path too long error, 169 and 199 are bitmap migration bugs, and 211 is a bug that shows up on Linux platforms, too. This is at least good evidence that these tests are not Linux-only. If they aren't suitable for other platforms, they should be disabled on a per-platform basis as appropriate. Therefore, let's switch these on and deal with the failures. Reviewed-by: Max Reitz Signed-off-by: John Snow --- tests/qemu-iotests/iotests.py | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index df0708923d..de8b904d87 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -896,9 +896,14 @@ def verify_protocol(supported=[], unsupported=[]): if not_sup or (imgproto in unsupported): notrun('not suitable for this protocol: %s' % imgproto) -def verify_platform(supported_oses=['linux']): - if True not in [sys.platform.startswith(x) for x in supported_oses]: - notrun('not suitable for this OS: %s' % sys.platform) +def verify_platform(supported=None, unsupported=None): + if unsupported is not None: + if any((sys.platform.startswith(x) for x in unsupported)): + notrun('not suitable for this OS: %s' % sys.platform) + + if supported is not None: + if not any((sys.platform.startswith(x) for x in supported)): + notrun('not suitable for this OS: %s' % sys.platform) def verify_cache_mode(supported_cache_modes=[]): if supported_cache_modes and (cachemode not in supported_cache_modes): @@ -989,7 +994,8 @@ def execute_unittest(output, verbosity, debug): sys.stderr.write(out) def execute_test(test_function=None, - supported_fmts=[], supported_oses=['linux'], + supported_fmts=[], + supported_platforms=None, supported_cache_modes=[], unsupported_fmts=[], supported_protocols=[], unsupported_protocols=[]): """Run either unittest or script-style tests.""" @@ -1006,7 +1012,7 @@ def execute_test(test_function=None, verbosity = 1 verify_image_format(supported_fmts, unsupported_fmts) verify_protocol(supported_protocols, unsupported_protocols) - verify_platform(supported_oses) + verify_platform(supported=supported_platforms) verify_cache_mode(supported_cache_modes) if debug: