diff options
author | Anton Antonov <anton.antonov@arm.com> | 2023-04-12 16:05:52 +0100 |
---|---|---|
committer | Armin Kuster <akuster808@gmail.com> | 2023-04-18 10:17:12 -0400 |
commit | d10f6f9ae37b79a987ffa4ace980b6dfab158729 (patch) | |
tree | 5d8288e69b51766a436a910dbb69b89bd53888a4 | |
parent | ac1b3ecabc0386e7ca9b7925ada0087d940040d2 (diff) | |
download | meta-security-d10f6f9ae37b79a987ffa4ace980b6dfab158729.tar.gz |
Fix PACKAGECONFIG check in Parsec OEQA tests
If PACKAGECONFIG is not defined in local.conf then
its default value is not included in cls.tc.td map.
Signed-off-by: Anton Antonov <Anton.Antonov@arm.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r-- | meta-parsec/lib/oeqa/runtime/cases/parsec.py | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/meta-parsec/lib/oeqa/runtime/cases/parsec.py b/meta-parsec/lib/oeqa/runtime/cases/parsec.py index 9df5bec..3729863 100644 --- a/meta-parsec/lib/oeqa/runtime/cases/parsec.py +++ b/meta-parsec/lib/oeqa/runtime/cases/parsec.py | |||
@@ -65,9 +65,18 @@ class ParsecTest(OERuntimeTestCase): | |||
65 | 65 | ||
66 | def check_packageconfig(self, prov): | 66 | def check_packageconfig(self, prov): |
67 | """ Check that the require provider is included in Parsec """ | 67 | """ Check that the require provider is included in Parsec """ |
68 | if prov not in self.tc.td['PACKAGECONFIG:pn-parsec-service']: | 68 | |
69 | if 'PACKAGECONFIG:pn-parsec-service' in self.tc.td.keys(): | ||
70 | providers = self.tc.td['PACKAGECONFIG:pn-parsec-service'] | ||
71 | else: | ||
72 | # PACKAGECONFIG is not defined in local.conf | ||
73 | # Let's use the default value | ||
74 | providers = "PKCS11 MBED-CRYPTO" | ||
75 | if 'tpm2' in self.tc.td['DISTRO_FEATURES']: | ||
76 | providers += " TPM" | ||
77 | if prov not in providers: | ||
69 | self.skipTest('%s provider is not included in Parsec. Parsec PACKAGECONFIG: "%s"' % \ | 78 | self.skipTest('%s provider is not included in Parsec. Parsec PACKAGECONFIG: "%s"' % \ |
70 | (prov, self.tc.td['PACKAGECONFIG:pn-parsec-service'])) | 79 | (prov, providers)) |
71 | 80 | ||
72 | def check_packages(self, prov, packages): | 81 | def check_packages(self, prov, packages): |
73 | """ Check for the required packages for Parsec providers software backends """ | 82 | """ Check for the required packages for Parsec providers software backends """ |