From patchwork Fri Dec 8 01:53:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alassane Yattara X-Patchwork-Id: 35890 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5F8ADC4167B for ; Fri, 8 Dec 2023 01:53:59 +0000 (UTC) Received: from mail.savoirfairelinux.com (mail.savoirfairelinux.com [208.88.110.44]) by mx.groups.io with SMTP id smtpd.web11.10346.1702000435627225278 for ; Thu, 07 Dec 2023 17:53:55 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@savoirfairelinux.com header.s=DFC430D2-D198-11EC-948E-34200CB392D2 header.b=Az+KvoPU; spf=pass (domain: savoirfairelinux.com, ip: 208.88.110.44, mailfrom: alassane.yattara@savoirfairelinux.com) Received: from localhost (localhost [127.0.0.1]) by mail.savoirfairelinux.com (Postfix) with ESMTP id 800EA9C33BA for ; Thu, 7 Dec 2023 20:53:54 -0500 (EST) Received: from mail.savoirfairelinux.com ([127.0.0.1]) by localhost (mail.savoirfairelinux.com [127.0.0.1]) (amavis, port 10032) with ESMTP id wMWBgCgZv8dt; Thu, 7 Dec 2023 20:53:54 -0500 (EST) Received: from localhost (localhost [127.0.0.1]) by mail.savoirfairelinux.com (Postfix) with ESMTP id 3C9799C33E2; Thu, 7 Dec 2023 20:53:54 -0500 (EST) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.savoirfairelinux.com 3C9799C33E2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=savoirfairelinux.com; s=DFC430D2-D198-11EC-948E-34200CB392D2; t=1702000434; bh=kXHiGTTvkSE94RAwVf732AXnJ0fLRLfhLbc5yfgtXf8=; h=From:To:Date:Message-Id:MIME-Version; b=Az+KvoPUTXlVjLAOWqOjto0XbVbQHP4UPSHYmkymoAwwG32wunxtWnS7Qvl85Jd24 8dhsJ2ZyePNzQM2eIbvlxzTYQpmZ1T2iTLAIV4djL4Huc8WtO39Eub6zTnnuJ+gRsK zokRzctYGpVg7ymIgi9WVMUedVY2yl8P5GvwWZ1nEJrVV/e3Q3XYdfj3LIvYFBS4Wt QbjeioKPPJ86gTn6s/Oz6mIwafDVq6bbRZMyKQTUm7PU9ZVrbqFw5X0dwLxdKW8KXH Q/B0zY/LU2r+Y8cuifBchyurXlDJw2tlHREjBRb3DkpTY6eJwqb6mqWeum9O4a0pfA bLGDIxg0cw4vg== X-Virus-Scanned: amavis at mail.savoirfairelinux.com Received: from mail.savoirfairelinux.com ([127.0.0.1]) by localhost (mail.savoirfairelinux.com [127.0.0.1]) (amavis, port 10026) with ESMTP id swHWnep3Y6V3; Thu, 7 Dec 2023 20:53:54 -0500 (EST) Received: from jedi.. (unknown [196.127.183.75]) by mail.savoirfairelinux.com (Postfix) with ESMTPSA id 5CEC19C33BA; Thu, 7 Dec 2023 20:53:53 -0500 (EST) From: Alassane Yattara To: toaster@lists.yoctoproject.org Cc: Alassane Yattara Subject: [PATCH 1/4] toaster/test: Ensure to kill toaster process create for tests functional Date: Fri, 8 Dec 2023 02:53:46 +0100 Message-Id: <20231208015349.678997-1-alassane.yattara@savoirfairelinux.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 08 Dec 2023 01:53:59 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/toaster/message/6067 Toaster background task runbuilds continu running when even if tests is done Signed-off-by: Alassane Yattara --- lib/toaster/tests/functional/functional_helpers.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/toaster/tests/functional/functional_helpers.py b/lib/toaster/tests/functional/functional_helpers.py index b80d403b..c37c5f8d 100644 --- a/lib/toaster/tests/functional/functional_helpers.py +++ b/lib/toaster/tests/functional/functional_helpers.py @@ -33,11 +33,11 @@ class SeleniumFunctionalTestCase(SeleniumTestCaseBase): # start toaster cmd = "bash -c 'source toaster start'" - p = subprocess.Popen( + cls.p = subprocess.Popen( cmd, cwd=os.environ.get("BUILDDIR"), shell=True) - if p.wait() != 0: + if cls.p.wait() != 0: raise RuntimeError("Can't initialize toaster") super(SeleniumFunctionalTestCase, cls).setUpClass() @@ -58,6 +58,7 @@ class SeleniumFunctionalTestCase(SeleniumTestCaseBase): with open(os.path.join(builddir, '.runbuilds.pid'), 'r') as f: runbuilds_pid = int(f.read()) os.kill(runbuilds_pid, signal.SIGTERM) + cls.p.kill() def get_URL(self):