[prev in list] [next in list] [prev in thread] [next in thread]
List: openembedded-core
Subject: [OE-core] [PATCH 19/23] oeqa/selftest/wic: cleanup WicTestCase.setUpLocal
From: "Ross Burton" <ross () burtonini ! com>
Date: 2022-03-31 18:29:11
Message-ID: 20220331182915.22128-19-ross.burton () arm ! com
[Download RAW message or body]
Content-Transfer-Encoding: quoted-printable
Use os.path.join to construct paths, and invoke bitbake once instead of
three times.
Signed-off-by: Ross Burton <ross.burton@arm.com>
---
meta/lib/oeqa/selftest/cases/wic.py | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/meta/lib/oeqa/selftest/cases/wic.py \
b/meta/lib/oeqa/selftest/cases/wic.py index 2eb80ac1941..6da70b8c287 100644
--- a/meta/lib/oeqa/selftest/cases/wic.py
+++ b/meta/lib/oeqa/selftest/cases/wic.py
@@ -75,22 +75,18 @@ class WicTestCase(OESelftestTestCase):
def setUpLocal(self):
"""This code is executed before each test method."""
- self.resultdir = self.builddir + "/wic-tmp/"
+ self.resultdir = os.path.join(self.builddir, "wic-tmp")
super(WicTestCase, self).setUpLocal()
# Do this here instead of in setUpClass as the base setUp does some
# clean up which can result in the native tools built earlier in
# setUpClass being unavailable.
if not WicTestCase.image_is_ready:
- if get_bb_var('USE_NLS') == 'yes':
- bitbake('wic-tools')
- else:
- self.skipTest('wic-tools cannot be built due its \
(intltool|gettext)-native dependency and NLS disable') + if \
get_bb_var('USE_NLS') != 'yes': + self.skipTest('wic-tools needs \
USE_NLS=yes')
- bitbake('core-image-minimal')
- bitbake('core-image-minimal-mtdutils')
+ bitbake('wic-tools core-image-minimal core-image-minimal-mtdutils')
WicTestCase.image_is_ready = True
-
rmtree(self.resultdir, ignore_errors=True)
def tearDownLocal(self):
--
2.25.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#163860): https://lists.openembedded.org/g/openembedded-core/message/163860
Mute This Topic: https://lists.openembedded.org/mt/90161358/4454766
Group Owner: openembedded-core+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [openembedded-core@marc.info]
-=-=-=-=-=-=-=-=-=-=-=-
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic