[OE-core] [PATCH] classes/testsdk: Split implementation into classes

richard.purdie at linuxfoundation.org richard.purdie at linuxfoundation.org
Thu Nov 15 22:48:31 UTC 2018


On Thu, 2018-11-15 at 16:28 -0600, Joshua Watt wrote:
> 
> ---- classes/testsdk(ext)?-oecore.bbclass ----
> 
> python do_testsdk() {
>     from oeqa.sdk.testsdk import TestSDK
>     t = TestSDK(d)
>     t.run()
> }
> 
> ----
> 
> It might make things a little more clear if I describe the end game;
> I
> would like to provide a different class to implement the MinGW SDK
> tests. This would be done by adding the following to the MinGW SDK
> machine.conf file (mingw32-common.inc):
> 
>  TESTSDK_CLASSES = "testsdk-mingw"
> 
> Then, adding a new class in meta-mingw
> 
> ---- classes/testsdk-mingw.bbclass ----
> 
> python do_testsdk() {
>     from oeqa.sdk.testsdkmingw import TestSDKMinGW
>     t = TestSDKMinGW(d)
>     t.run()
> }
> 
> ----
> 
> AFAICT, this is pretty similar to how the package managers are
> working.
> 
> Did you had something else in mind?

We're thinking along similar lines but in pseudo-code I was thinking
something more like:

SDKCLASSNAME ??= "default"

python do_testsdk() {
     sdkclass = d.getVar("SDKCLASSNAME")
     from oeqa.sdk.testsdkmingw import sdkclass
     t = sdkclass(d)
     t.run()
}
 

as there should be some way to structure this so we don't need so many
bbclass files...

Cheers,

Richard



More information about the Openembedded-core mailing list