summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/lib/oeqa/selftest/cases/runtime_test.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/meta/lib/oeqa/selftest/cases/runtime_test.py b/meta/lib/oeqa/selftest/cases/runtime_test.py
index 673b1998ac..7d105f2fed 100644
--- a/meta/lib/oeqa/selftest/cases/runtime_test.py
+++ b/meta/lib/oeqa/selftest/cases/runtime_test.py
@@ -4,6 +4,7 @@ from oeqa.core.decorator.oeid import OETestID
4import os 4import os
5import re 5import re
6import tempfile 6import tempfile
7import shutil
7 8
8class TestExport(OESelftestTestCase): 9class TestExport(OESelftestTestCase):
9 10
@@ -147,19 +148,22 @@ class TestImage(OESelftestTestCase):
147 features += 'PACKAGE_CLASSES = "package_rpm"\n' 148 features += 'PACKAGE_CLASSES = "package_rpm"\n'
148 149
149 # Enable package feed signing 150 # Enable package feed signing
150 self.gpg_home = tempfile.TemporaryDirectory(prefix="oeqa-feed-sign-") 151 self.gpg_home = tempfile.mkdtemp(prefix="oeqa-feed-sign-")
151 signing_key_dir = os.path.join(self.testlayer_path, 'files', 'signing') 152 signing_key_dir = os.path.join(self.testlayer_path, 'files', 'signing')
152 runCmd('gpg --batch --homedir %s --import %s' % (self.gpg_home.name, os.path.join(signing_key_dir, 'key.secret'))) 153 runCmd('gpg --batch --homedir %s --import %s' % (self.gpg_home, os.path.join(signing_key_dir, 'key.secret')))
153 features += 'INHERIT += "sign_package_feed"\n' 154 features += 'INHERIT += "sign_package_feed"\n'
154 features += 'PACKAGE_FEED_GPG_NAME = "testuser"\n' 155 features += 'PACKAGE_FEED_GPG_NAME = "testuser"\n'
155 features += 'PACKAGE_FEED_GPG_PASSPHRASE_FILE = "%s"\n' % os.path.join(signing_key_dir, 'key.passphrase') 156 features += 'PACKAGE_FEED_GPG_PASSPHRASE_FILE = "%s"\n' % os.path.join(signing_key_dir, 'key.passphrase')
156 features += 'GPG_PATH = "%s"\n' % self.gpg_home.name 157 features += 'GPG_PATH = "%s"\n' % self.gpg_home
157 self.write_config(features) 158 self.write_config(features)
158 159
159 # Build core-image-sato and testimage 160 # Build core-image-sato and testimage
160 bitbake('core-image-full-cmdline socat') 161 bitbake('core-image-full-cmdline socat')
161 bitbake('-c testimage core-image-full-cmdline') 162 bitbake('-c testimage core-image-full-cmdline')
162 163
164 # remove the oeqa-feed-sign temporal directory
165 shutil.rmtree(self.gpg_home, ignore_errors=True)
166
163class Postinst(OESelftestTestCase): 167class Postinst(OESelftestTestCase):
164 @OETestID(1540) 168 @OETestID(1540)
165 def test_verify_postinst(self): 169 def test_verify_postinst(self):