[OE-core] [PATCH] oe-selftest: support selftests from other layers

Liu, Sharron sharron.liu at intel.com
Fri Aug 7 03:43:47 UTC 2015


Hi Chris,
Thanks for your inputs. I tested my case with poky master which includes the two commitments you mentioned:
    https://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=d2023c34e4c3735d919c35d80daf991aab579500
https://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=51d760e2a7e22f1b07608fc925da343e56a9ae74
In my observation it still failed at my case.

In my test case I have:
poky_root/meta-mylayer/lib/oeqa/selftest/subdirs/mytest.py

I type:
"oe-selftest --list-modules"
And I expect “subdirs.mytest” being listed.

I type:
"oe-selftest --run-tests subdirs.mytest"
And I expect “mytest” being run.

This case still failed without my patch. Attached the log file for your ref.

Regards,
Sharron

From: kergoth at gmail.com [mailto:kergoth at gmail.com] On Behalf Of Christopher Larson
Sent: Wednesday, August 5, 2015 11:07 PM
To: Liu, Sharron
Cc: Patches and discussions about the oe-core layer
Subject: Re: [OE-core] [PATCH] oe-selftest: support selftests from other layers


On Wed, Aug 5, 2015 at 12:17 AM, LIU, Sharron <sharron.liu at intel.com<mailto:sharron.liu at intel.com>> wrote:
[YOCTO #7865] https://bugzilla.yoctoproject.org/show_bug.cgi?id=7865

This script is extended to detect and run tests from all BBLAYERS added to
BBPATH. Tests can be put in any sub-dir, except for "files" which is treated
as test dependent files.

To detect tests, this patch goes through "lib/oeqa/selftest/" of every layer
added to BBPATH.
To support sub-dir, this patch list test module with its sub-dirs prefix.
To run tests, this patch adds tests package path into "sys.path" then reload
"oeqa.selftest".

Signed-off-by: LIU, Sharron <sharron.liu at intel.com<mailto:sharron.liu at intel.com>>

This was implemented as a part of the work to do the same for devtool & recipetool, see https://bugzilla.yoctoproject.org/show_bug.cgi?id=7865#c10 and https://bugzilla.yoctoproject.org/show_bug.cgi?id=7625#c3:

    https://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=d2023c34e4c3735d919c35d80daf991aab579500
    https://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=51d760e2a7e22f1b07608fc925da343e56a9ae74
--
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20150807/5153bfc4/attachment-0002.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 7865.log
Type: application/octet-stream
Size: 1025 bytes
Desc: 7865.log
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20150807/5153bfc4/attachment-0002.obj>


More information about the Openembedded-core mailing list