Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Gyorgy Sarvari <skandigraun@gmail.com>
To: "Tran (US), Thune A" <thune.a.tran@boeing.com>,
	"openembedded-core@lists.openembedded.org"
	<openembedded-core@lists.openembedded.org>
Subject: Re: [OE-core] [PATCH] oeqa/sdk/sdktest: Add test discovery across layers
Date: Wed, 16 Apr 2025 23:16:27 +0200	[thread overview]
Message-ID: <7089cbb2-f297-47f6-bfa6-df0112d752ec@gmail.com> (raw)
In-Reply-To: <SA1P110MB22502577597BE3CD0A37FB9CB7BDA@SA1P110MB2250.NAMP110.PROD.OUTLOOK.COM>

On 4/16/25 22:54, Tran (US), Thune A wrote:
>> The same issue is also present for sdkext - since you are already on
>> this, do you think you could make that work too?
> Thanks for pointing that out. A quick look at sdkext. It's possible to make 
> it work for it. I'm open to submitting a similar patch for sdkext. I'm not 
> immediately set up to test it. Would you be able to help verify the patch 
> for sdkext and also sign off on it?

[Just to have it here also, not only in private messages]

Yeah, I think I should be able to do that - I have an extensible sdk set
up, and some classes also that I can use for testing.


>> On 4/16/25 18:41, Thune Tran via lists.openembedded.org wrote:
>>> The testsdk task only loads SDK tests from the openembedded-core
>>> layer's meta/lib/oeqa/sdk/cases/.
>>>
>>> This patch implements test discovery to include SDK tests from all
>>> configured layers that mirror <LAYER_DIR>/lib/oeqa/sdk/cases/. The
>>> implementation mirrors get_runtime_paths() in meta/classes-
>>> recipe/testimage.
>>>
>>> Tested by:
>>>
>>> 1. Adding SDK test cases to <LAYER_DIR>/lib/oeqa/sdk/cases/ and
>>>    verifying they are discovered and executed with no errors. 2.
>>>    Verifying existing SDK test cases in openembedded-core layer are
>>>    discovered and executed with no errors.
>>> Signed-off-by: Thune Tran <thune.a.tran@boeing.com>
>>> Signed-off-by: Chuck Wolber <chuck.wolber@boeing.com>
>>> ---
>>>  meta/lib/oeqa/sdk/testsdk.py | 16 +++++++++++++++-
>>>  1 file changed, 15 insertions(+), 1 deletion(-)
>>> diff --git a/meta/lib/oeqa/sdk/testsdk.py b/meta/lib/oeqa/sdk/testsdk.py
>>> index 518b09febb..505add8f8c 100644
>>> --- a/meta/lib/oeqa/sdk/testsdk.py
>>> +++ b/meta/lib/oeqa/sdk/testsdk.py
>>> @@ -31,6 +31,20 @@ class TestSDK(TestSDKBase):
>>>      context_class = OESDKTestContext
>>>      test_type = 'sdk'
>>> +    def get_sdk_paths(self, d):
>>> +        """
>>> +        Returns a list of paths where SDK test must reside.
>>> +
>>> +        SDK tests are expected in <LAYER_DIR>/lib/oeqa/sdk/cases/
>>> +        """
>>> +        paths = []
>>> +
>>> +        for layer in d.getVar('BBLAYERS').split():
>>> +            path = os.path.join(layer, 'lib/oeqa/sdk/cases')
>>> +            if os.path.isdir(path):
>>> +                paths.append(path)
>>> +        return paths
>>> +
>>>      def get_tcname(self, d):
>>>          """
>>>          Get the name of the SDK file
>>> @@ -114,7 +128,7 @@ class TestSDK(TestSDKBase):
>>>                  host_pkg_manifest=host_pkg_manifest, **context_args)
>>>              try:
>>> -                tc.loadTests(self.context_executor_class.default_cases)
>>> +                tc.loadTests(self.get_sdk_paths(d))
>>>              except Exception as e:
>>>                  import traceback
>>>                  bb.fatal("Loading tests failed:\n%s" % traceback.format_exc())
>>>
>>>
>


  reply	other threads:[~2025-04-16 21:16 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-16 16:41 [PATCH] oeqa/sdk/sdktest: Add test discovery across layers Thune Tran
2025-04-16 17:23 ` [OE-core] " Gyorgy Sarvari
2025-04-16 20:54   ` Tran (US), Thune A
2025-04-16 21:16     ` Gyorgy Sarvari [this message]
2025-04-16 22:07 ` Richard Purdie
2025-04-17  4:39   ` Chuck Wolber
2025-04-17 10:06     ` Gyorgy Sarvari
2025-04-17 11:04     ` Richard Purdie
2025-04-17 12:54       ` Tran (US), Thune A
2025-04-17 13:03         ` Richard Purdie
2025-04-17 15:53           ` Tran (US), Thune A
     [not found]           ` <18372610739395C0.11203@lists.openembedded.org>
2025-04-21 19:21             ` Tran (US), Thune A

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7089cbb2-f297-47f6-bfa6-df0112d752ec@gmail.com \
    --to=skandigraun@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=thune.a.tran@boeing.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox