aboutsummaryrefslogtreecommitdiffstats
path: root/lib/toaster
diff options
context:
space:
mode:
authorAlassane Yattara <alassane.yattara@savoirfairelinux.com>2023-12-08 02:53:16 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-12-08 17:17:23 +0000
commite885863dffebab77f501a58df172926aafec5623 (patch)
tree996f427921fcd9563c34f54b2951dfe628ea6082 /lib/toaster
parentaf31116f0017912fc5a58a5976c814b6b326985f (diff)
downloadbitbake-e885863dffebab77f501a58df172926aafec5623.tar.gz
toaster/tests: Ensure to kill toaster process create for tests functional
Toaster background task runbuilds continu running when even if tests is done Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/toaster')
-rw-r--r--lib/toaster/tests/functional/functional_helpers.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/toaster/tests/functional/functional_helpers.py b/lib/toaster/tests/functional/functional_helpers.py
index b80d403be..c37c5f8d2 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):