From patchwork Mon Aug 22 16:56:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 599182 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:4388:0:0:0:0 with SMTP id w8csp1870911mae; Mon, 22 Aug 2022 11:22:32 -0700 (PDT) X-Google-Smtp-Source: AA6agR75k/qRKV5fPREyUlg7PUzLhhdsO+98wxRYNn9Cw49UjRcqDUo6NWVUbheKn+ew5/PNQQ67 X-Received: by 2002:a05:622a:24c:b0:343:7d3b:4953 with SMTP id c12-20020a05622a024c00b003437d3b4953mr16347686qtx.562.1661192551960; Mon, 22 Aug 2022 11:22:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661192551; cv=none; d=google.com; s=arc-20160816; b=xDN/f9ZCrQQywBBRdDFggsGmK3tY2MnI6Xh1ATeXnQBoAk4u3swS04MxrU/M7PoQfh XbYjPXWlVMOQWfdr0QUdvsHHv7oR+j/2KlqZTVr2VS7u8xvsaXnFfo14ttBHe+6C16Cx FMZzgLdigW+GGRK1wcOYLwFkbfDobNjrIQQB9pkonVKnGBSXvpVuO9jbt7oleI83BOyN Am3CmfKdjIwLhJ4whILkXN1j76IS9OMH58lxoXFwe+KgvMkNkKpwW5RQd5n6o9dYlqtr s/rxPW4/rjhWlrF69Est29/3S8+SCA1RIu1/m4ga/NgsuwEA1T8SXEF/CmK/1bKTO6sa FxDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=WyNPEcxZT+0dqh6qBfly/w3zPsNi3DOLgNMcDAo03+c=; b=wufdqTVFwqhKW+JSgIuBMu6fJrwrfviC9/DoQCb6iaA2NnAMBIoJp2yWCfSKa+u4Ns 8IpHlbpGGF/dAaVEI+6mvI6oIq4CTGRsCF3MZcFpImTdSILbrOkzMnFV83dUoScuLbQh 4MEZhQTnALV7kPMTYrN8OOyid6VNRMbqpt27ey2gcXiaadgVINmcK2RGvfgjAl2flxWP 2p16pfftIwVEAvYI3prdbWVVJg+Dl9GNN+V+GLEzoOI53M/u5+QpX0Bt7U4ocHWYIWBj 0FUYSBMPPyMpsnphlOQxlEeigt9W0lreNIbcdo6xSs7k07DjW/shN2x31+dBBuLsDY8s OvkQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=xp6Lvgda; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g5-20020a05620a40c500b006b5ead97164si5734744qko.599.2022.08.22.11.22.31 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 22 Aug 2022 11:22:31 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=xp6Lvgda; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:35024 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oQC4F-00036d-H5 for patch@linaro.org; Mon, 22 Aug 2022 14:22:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59034) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oQAil-0008JQ-9I for qemu-devel@nongnu.org; Mon, 22 Aug 2022 12:56:15 -0400 Received: from mail-ej1-x634.google.com ([2a00:1450:4864:20::634]:33299) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oQAii-0005zi-Kz for qemu-devel@nongnu.org; Mon, 22 Aug 2022 12:56:14 -0400 Received: by mail-ej1-x634.google.com with SMTP id j21so17064593ejs.0 for ; Mon, 22 Aug 2022 09:56:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=WyNPEcxZT+0dqh6qBfly/w3zPsNi3DOLgNMcDAo03+c=; b=xp6Lvgda1S5jVv91RNXM1Y9TWMqxk/95sKnoDb/YZqb84DuXEkbDCR1DI3qrz/L/5e lVr0GV2/UtY45KU3dnGsOp2RGUbyjndps3zFXtrR/xp0Dqol65eZSX5M5L7uzfI7uKcF p+C6A/YsVuSfFQ1bwMam2duDCJcdCyzMGlifK0zoVnEnIrbPSu+An++kSoXBxXIInoEh TjoKyr1cYIH/Hbnh7ET2jjSHVwtFoziMAXZIlHKyWP5aBBi1oBy57Q8MMCh8xo7mm6F7 7BWXr6VLw3E2AK0KIoiXtvxFxKUzS9rUiFCseGA0VgfrnujQt1AfHkMfIzt1PHauNWb0 qLNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=WyNPEcxZT+0dqh6qBfly/w3zPsNi3DOLgNMcDAo03+c=; b=gtsP21SSHLIowhBdQgI4jXEaaG1q5AmxPRGnS0eLFn8SCPlKGLy4Or3JnbrUbKP1oS hTtUVBMXAAuqGwJmqtJbSri06vV2Bu5H4jM1XIslax4CLEEHJchjEQ7gHOCVrTQOtsps gFaNNMt4stREm33mYgYgIxRfx/vsp7UBwnQ4cDvscJYLEBNpvPATxA7Hit16y2eXU+sQ IaUx2OUgcIssMyIJIY7wYcSfOcfAvIl8RLj0XaJxkVbHSyp/r1yWK0TWlGNb7Yc/IGoq sIfnamS3txL5wIDx4VSuVxdw9zJaq3LzYLNjMEMO94Q76jpWE7IkKGGLz1vIVD6OIfgJ q0mA== X-Gm-Message-State: ACgBeo1MNpL/A3IAQJEseJ+PN6FhCYQJ0OJ6iFD8cf7Uk9030LRYa37M S2Adx+wiIMzFpEOHAEt82tCReg== X-Received: by 2002:a17:907:2e01:b0:730:a098:7257 with SMTP id ig1-20020a1709072e0100b00730a0987257mr13969563ejc.705.1661187371286; Mon, 22 Aug 2022 09:56:11 -0700 (PDT) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id c15-20020a170906694f00b0073d6cfdc44dsm3095409ejs.115.2022.08.22.09.56.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Aug 2022 09:56:10 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 19A841FFBA; Mon, 22 Aug 2022 17:56:09 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: Thomas Huth , "Dr . David Alan Gilbert" , =?utf-8?q?Alex_Benn=C3=A9e?= , Juan Quintela , Laurent Vivier , Paolo Bonzini Subject: [PATCH v1 2/6] tests/qtest/migration-test: Only wait for serial output where migration succeeds Date: Mon, 22 Aug 2022 17:56:04 +0100 Message-Id: <20220822165608.2980552-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220822165608.2980552-1-alex.bennee@linaro.org> References: <20220822165608.2980552-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::634; envelope-from=alex.bennee@linaro.org; helo=mail-ej1-x634.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Thomas Huth Waiting for the serial output can take a couple of seconds - and since we're doing a lot of migration tests, this time easily sums up to multiple minutes. But if a test is supposed to fail, it does not make much sense to wait for the source to be in the right state first, so we can skip the waiting here. This way we can speed up all tests where the migration is supposed to fail. In the gitlab-CI gprov-gcov test, each of the migration-tests now run two minutes faster! Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Thomas Huth Message-Id: <20220819053802.296584-2-thuth@redhat.com> Signed-off-by: Alex Bennée Reviewed-by: Juan Quintela --- tests/qtest/migration-test.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c index 520a5f917c..7be321b62d 100644 --- a/tests/qtest/migration-test.c +++ b/tests/qtest/migration-test.c @@ -1307,7 +1307,9 @@ static void test_precopy_common(MigrateCommon *args) } /* Wait for the first serial output from the source */ - wait_for_serial("src_serial"); + if (args->result == MIG_TEST_SUCCEED) { + wait_for_serial("src_serial"); + } if (!args->connect_uri) { g_autofree char *local_connect_uri =