From nobody Fri Apr 26 18:24:54 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) client-ip=63.128.21.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1599657028; cv=none; d=zohomail.com; s=zohoarc; b=Vj6lniB+e/TE3yhi9Z2b4aisSScRiPNEeTkLglDGHBBiw+8Ld2BRYpwEBxF9NR5j6mCBEymmRuGhVl7jW0FV20tn05zlWvmmna4c3lur0cfYBEzv4OUexYxl8z1ipvps7Dj66hxCUykS8jUiYfztOX0+IBLrd0lAVHz325YLLUU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1599657028; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=bvAiyWX1sFNK5Ne9X/CesANfQqMTipQwL5X8T5AtHcA=; b=mh92BjegDixjWOo1I3Uyxg3j6La5wNi7OFyK5QYSTE9zzaO4HUj0VXlX0/HHVtEYVsMsUzrRbYJjQKcsXK3nFSmPrGzzAfJNRbd9naJkXNYDPlM49hGAF2XkuK0yH63fjAw0GnZj6z7NdTeyCqPIxPxm3dQDkmZYnkuHRdKQ7c8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by mx.zohomail.com with SMTPS id 1599657028501855.3905361465856; Wed, 9 Sep 2020 06:10:28 -0700 (PDT) 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-122-zt4qxnBlMW-Q8qpxR5VEMg-1; Wed, 09 Sep 2020 09:10:24 -0400 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 9BE2064088; Wed, 9 Sep 2020 13:10:17 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id AA05619936; Wed, 9 Sep 2020 13:10:16 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id E553097319; Wed, 9 Sep 2020 13:10:15 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 089DAEKZ005101 for ; Wed, 9 Sep 2020 09:10:14 -0400 Received: by smtp.corp.redhat.com (Postfix) id 3490F1A886; Wed, 9 Sep 2020 13:10:14 +0000 (UTC) Received: from harajuku.usersys.redhat.com (unknown [10.40.194.150]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4D58519936 for ; Wed, 9 Sep 2020 13:10:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1599657027; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=bvAiyWX1sFNK5Ne9X/CesANfQqMTipQwL5X8T5AtHcA=; b=c9/sULsBOLdA9J5liNrHsIwG1Lhg7ZaQiArUiZOdDfQRfd1XwjwjmXxuoeWi6lB/9C2YfD 1gjq5ObxXAEPbxlM+1dK9N2p8vfYvYu8E7nEgqOfER0va52/lLZSOHtoqpvXDCjGt91D/R nb7BoY9/sf4wmAkwLAgyMiGmFkzkbWM= X-MC-Unique: zt4qxnBlMW-Q8qpxR5VEMg-1 From: Andrea Bolognani To: libvir-list@redhat.com Subject: [libvirt PATCH 1/2] meson: Rename tests-related build options Date: Wed, 9 Sep 2020 15:10:05 +0200 Message-Id: <20200909131006.128717-2-abologna@redhat.com> In-Reply-To: <20200909131006.128717-1-abologna@redhat.com> References: <20200909131006.128717-1-abologna@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0.001 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" We already have two options that influence how 'ninja test' behaves and we're about to introduce a third one, so it makes sense to give them consistent names. Signed-off-by: Andrea Bolognani --- libvirt.spec.in | 2 +- meson.build | 6 +++--- meson_options.txt | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/libvirt.spec.in b/libvirt.spec.in index 379cf0d9be..90aeb6210c 100644 --- a/libvirt.spec.in +++ b/libvirt.spec.in @@ -1185,7 +1185,7 @@ export SOURCE_DATE_EPOCH=3D$(stat --printf=3D'%Y' %{_= specdir}/%{name}.spec) -Dqemu_group=3D%{qemu_group} \ -Dtls_priority=3D%{tls_priority} \ %{?enable_werror} \ - -Dexpensive_tests=3Denabled \ + -Dtests_expensive=3Denabled \ -Dinit_script=3Dsystemd \ %{?arg_login_shell} =20 diff --git a/meson.build b/meson.build index 33eaa9ff56..0820e4c895 100644 --- a/meson.build +++ b/meson.build @@ -127,14 +127,14 @@ endif =20 # test options =20 -if get_option('expensive_tests').auto() +if get_option('tests_expensive').auto() use_expensive_tests =3D not git else - use_expensive_tests =3D get_option('expensive_tests').enabled() + use_expensive_tests =3D get_option('tests_expensive').enabled() endif =20 coverage_flags =3D [] -if get_option('test_coverage') +if get_option('tests_coverage') coverage_flags =3D [ '-fprofile-arcs', '-ftest-coverage', diff --git a/meson_options.txt b/meson_options.txt index 7838630c1e..43ce9b83de 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -3,8 +3,8 @@ option('packager', type: 'string', value: '', description: = 'Extra packager name' option('packager_version', type: 'string', value: '', description: 'Extra = packager version') option('system', type: 'boolean', value: false, description: 'Set install = paths to system ones') option('runstatedir', type: 'string', value: '', description: 'State direc= tory for temporary sockets, pid files, etc') -option('expensive_tests', type: 'feature', value: 'auto', description: 'se= t the default for enabling expensive tests (long timeouts), use VIR_TEST_EX= PENSIVE to override') -option('test_coverage', type: 'boolean', value: false, description: 'turn = on code coverage instrumentation') +option('tests_expensive', type: 'feature', value: 'auto', description: 'se= t the default for enabling expensive tests (long timeouts), use VIR_TEST_EX= PENSIVE to override') +option('tests_coverage', type: 'boolean', value: false, description: 'turn= on code coverage instrumentation') option('git_werror', type: 'feature', value: 'auto', description: 'use -We= rror if building from GIT') option('rpath', type: 'feature', value: 'auto', description: 'whether to i= nclude rpath information in installed binaries and libraries') =20 --=20 2.26.2 From nobody Fri Apr 26 18:24:54 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1599657034; cv=none; d=zohomail.com; s=zohoarc; b=dx2u04XydJTGf5pRjXvpfeIJq2Wx0sirfuEwYii7T9lUwSIRrXbuOfR4R6d7K2iVffM1y5xAZitEj+MCnGEEAThCxSFbcYAvyjo1ch5fe5UJnO7EjMU9nRxjVNJ3P/vc2zYeMuYlgN6TW0BuvJAmbPYg7v7rHey4+7zRPsG4vZc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1599657034; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=+9uLkKOe4uxDgzMthtc8WV6YrIM1GyZ7etoidAVFfZY=; b=BO4ClqWN5OvrCxRi3KF4DjpVqu+hewT3jZqduRcoQu2n1/pcs1K00833HEzq7ZE+f3Q5qDBoIL6n7Ljqf/rjUigVIT2P0F8gE8b56cSvzO9dQbzc6z91Yza46zbLzSynxk/bFSaf63XulaScGJFAFC424Iha8X3DhGeO7qPQfk0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1599657034896395.043285550767; Wed, 9 Sep 2020 06:10:34 -0700 (PDT) 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-6-MbDhqvX3PbCMR4SFmlLGXQ-1; Wed, 09 Sep 2020 09:10:31 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id F105A18BFEC8; Wed, 9 Sep 2020 13:10:24 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id CCB5A83562; Wed, 9 Sep 2020 13:10:24 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 98B4C1826D2A; Wed, 9 Sep 2020 13:10:24 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 089DAFHm005115 for ; Wed, 9 Sep 2020 09:10:15 -0400 Received: by smtp.corp.redhat.com (Postfix) id 6F7591A886; Wed, 9 Sep 2020 13:10:15 +0000 (UTC) Received: from harajuku.usersys.redhat.com (unknown [10.40.194.150]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 9975219936 for ; Wed, 9 Sep 2020 13:10:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1599657033; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=+9uLkKOe4uxDgzMthtc8WV6YrIM1GyZ7etoidAVFfZY=; b=Yo+PbdPvq03utk5zVnwHNeoNgTzbZQdWxXmTTvMXGd+KmPfwFkygGWXOy6L4uTVLjvtQfB PTcEwwl2zkOVMPVIa2GWmvy9PSaNjpKuuwvFii6DSkYVFXB/EEbNZUQOg4NCoxJx82o1AU h0sA3W+pcdpKU/YB9qnxhayLEo0MXYE= X-MC-Unique: MbDhqvX3PbCMR4SFmlLGXQ-1 From: Andrea Bolognani To: libvir-list@redhat.com Subject: [libvirt PATCH 2/2] meson: Add tests_timeout build option Date: Wed, 9 Sep 2020 15:10:06 +0200 Message-Id: <20200909131006.128717-3-abologna@redhat.com> In-Reply-To: <20200909131006.128717-1-abologna@redhat.com> References: <20200909131006.128717-1-abologna@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0.001 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The default timeout for tests is 30s, but that's not always enough time: the Valgrind test, for example, are currently special-cased because they take longer, and on certain architectures where powerful hardware is not (yet) available even the basic test programs might take more than 30s to complete. A concrete example of this happening and preventing a package build from finishing: https://buildd.debian.org/status/fetch.php?pkg=3Dlibvirt&arch=3Driscv64&v= er=3D6.7.0-1&stamp=3D1599587548&raw=3D0 Make it possible to configure a different timeout for tests. Signed-off-by: Andrea Bolognani --- meson.build | 2 ++ meson_options.txt | 1 + tests/meson.build | 6 +++--- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/meson.build b/meson.build index 0820e4c895..2d5b364979 100644 --- a/meson.build +++ b/meson.build @@ -141,6 +141,8 @@ if get_option('tests_coverage') ] endif =20 +tests_timeout =3D get_option('tests_timeout') + =20 # Detect when running under the clang static analyzer's scan-build driver # or Coverity-prevent's cov-build. Define STATIC_ANALYSIS accordingly. diff --git a/meson_options.txt b/meson_options.txt index 43ce9b83de..d048ed8dd6 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -5,6 +5,7 @@ option('system', type: 'boolean', value: false, description= : 'Set install paths option('runstatedir', type: 'string', value: '', description: 'State direc= tory for temporary sockets, pid files, etc') option('tests_expensive', type: 'feature', value: 'auto', description: 'se= t the default for enabling expensive tests (long timeouts), use VIR_TEST_EX= PENSIVE to override') option('tests_coverage', type: 'boolean', value: false, description: 'turn= on code coverage instrumentation') +option('tests_timeout', type: 'integer', value: 30, description: 'time (in= seconds) after which a test case is considered failed') option('git_werror', type: 'feature', value: 'auto', description: 'use -We= rror if building from GIT') option('rpath', type: 'feature', value: 'auto', description: 'whether to i= nclude rpath information in installed binaries and libraries') =20 diff --git a/tests/meson.build b/tests/meson.build index 0a204c46e4..322904910e 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -582,7 +582,7 @@ foreach data : tests ], export_dynamic: true, ) - test(data['name'], test_bin, env: tests_env) + test(data['name'], test_bin, env: tests_env, timeout: tests_timeout) endforeach =20 =20 @@ -681,7 +681,7 @@ endif =20 foreach name : test_scripts script =3D find_program(name) - test(name, script, env: tests_env) + test(name, script, env: tests_env, timeout: tests_timeout) endforeach =20 add_test_setup( @@ -701,6 +701,6 @@ add_test_setup( '--suppressions=3D@0@'.format(meson.current_source_dir() / '.valgrind.= supp'), '--error-exitcode=3D1', ], - # default timeout in meson is 30s + # Tests take a lot longer when run under Valgrind timeout_multiplier: 4, ) --=20 2.26.2