summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/oeqa/selftest/updater.py22
1 files changed, 22 insertions, 0 deletions
diff --git a/lib/oeqa/selftest/updater.py b/lib/oeqa/selftest/updater.py
index eb09302..2723b4a 100644
--- a/lib/oeqa/selftest/updater.py
+++ b/lib/oeqa/selftest/updater.py
@@ -57,6 +57,28 @@ class HsmTests(oeSelfTest):
57 57
58class GeneralTests(oeSelfTest): 58class GeneralTests(oeSelfTest):
59 59
60 def test_feature_sota(self):
61 result = get_bb_var('DISTRO_FEATURES').find('sota')
62 self.assertNotEqual(result, -1, 'Feature "sota" not set at DISTRO_FEATURES');
63
64 def test_feature_systemd(self):
65 result = get_bb_var('DISTRO_FEATURES').find('systemd')
66 self.assertNotEqual(result, -1, 'Feature "systemd" not set at DISTRO_FEATURES');
67
68 def test_credentials(self):
69 bitbake('core-image-minimal')
70 credentials = get_bb_var('SOTA_PACKED_CREDENTIALS')
71 # skip the test if the variable SOTA_PACKED_CREDENTIALS is not set
72 if credentials is None:
73 raise unittest.SkipTest("Variable 'SOTA_PACKED_CREDENTIALS' not set.")
74 # Check if the file exists
75 self.assertTrue(os.path.isfile(credentials), "File %s does not exist" % credentials)
76 deploydir = get_bb_var('DEPLOY_DIR_IMAGE')
77 imagename = get_bb_var('IMAGE_LINK_NAME', 'core-image-minimal')
78 # Check if the credentials are included in the output image
79 result = runCmd('tar -jtvf %s/%s.tar.bz2 | grep sota_provisioning_credentials.zip' % (deploydir, imagename), ignore_status=True)
80 self.assertEqual(result.status, 0, "Status not equal to 0. output: %s" % result.output)
81
60 def test_java(self): 82 def test_java(self):
61 result = runCmd('which java', ignore_status=True) 83 result = runCmd('which java', ignore_status=True)
62 self.assertEqual(result.status, 0, "Java not found.") 84 self.assertEqual(result.status, 0, "Java not found.")