[OE-core] [PATCH v2 25/28] oeqa/oetest.py: SDK{Ext, } improve host and target manifest load.
Paul Eggleton
paul.eggleton at linux.intel.com
Thu Feb 4 18:35:27 UTC 2016
On Tue, 02 Feb 2016 18:30:37 Aníbal Limón wrote:
> Don't pass variable name instead of it expands the host and target
> manifest at init of the classes.
>
> Signed-off-by: Aníbal Limón <anibal.limon at linux.intel.com>
> ---
> meta/lib/oeqa/oetest.py | 16 ++++++++--------
> 1 file changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/meta/lib/oeqa/oetest.py b/meta/lib/oeqa/oetest.py
> index 6a95c28..80b40b6 100644
> --- a/meta/lib/oeqa/oetest.py
> +++ b/meta/lib/oeqa/oetest.py
> @@ -382,18 +382,18 @@ class SDKTestContext(TestContext):
> self.sdktestdir = sdktestdir
> self.sdkenv = sdkenv
>
> - if not hasattr(self, 'target_manifest_name'):
> - self.target_manifest_name = "SDK_TARGET_MANIFEST"
> + if not hasattr(self, 'target_manifest'):
> + self.target_manifest = d.getVar("SDK_TARGET_MANIFEST", True)
> try:
> - with open(d.getVar(self.target_manifest_name, True)) as f:
> + with open(self.target_manifest) as f:
> self.pkgmanifest = f.read()
> except IOError as e:
> bb.fatal("No package manifest file found. Did you build the sdk
> image?\n%s" % e)
>
> - if not hasattr(self, 'host_manifest_name'):
> - self.host_manifest_name = "SDK_HOST_MANIFEST"
> + if not hasattr(self, 'host_manifest'):
> + self.host_manifest = d.getVar("SDK_HOST_MANIFEST", True)
> try:
> - with open(d.getVar(self.host_manifest_name, True)) as f:
> + with open(self.host_manifest) as f:
> self.hostpkgmanifest = f.read()
> except IOError as e:
> bb.fatal("No host package manifest file found. Did you build
> the sdk image?\n%s" % e) @@ -410,8 +410,8 @@ class
> SDKTestContext(TestContext):
>
> class SDKExtTestContext(SDKTestContext):
> def __init__(self, d, sdktestdir, sdkenv):
> - self.target_manifest_name = "SDK_EXT_TARGET_MANIFEST"
> - self.host_manifest_name = "SDK_EXT_HOST_MANIFEST"
> + self.target_manifest = d.getVar("SDK_EXT_TARGET_MANIFEST", True)
> + self.host_manifest = d.getVar("SDK_EXT_HOST_MANIFEST", True)
>
> super(SDKExtTestContext, self).__init__(d, sdktestdir, sdkenv)
Please squash this into the earlier commit where the original logic was added.
Thanks,
Paul
--
Paul Eggleton
Intel Open Source Technology Centre
More information about the Openembedded-core
mailing list