Commit Graph

6 Commits

Author SHA1 Message Date
Aníbal Limón
aa6e333de9 oeqa/core/threaded: Don't assume that results exists on logDetails
(From OE-Core rev: 7beed75c97a78e945e44a55b28f0f463cd6c8dcd)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-23 11:44:12 +01:00
Aníbal Limón
9ea42734c0 oeqa/core/threaded: Add OETestContextThreaded class
This class sets the {loader,runner}Class to the threaded versions and
overrides loadTests method to be able specify the process_num.

[YOCTO #11450]

(From OE-Core rev: 3ec0d3825aa31219e0ccabc1f158d3a2f8adbda2)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-02 13:36:14 +01:00
Aníbal Limón
6632277986 oeqa/core/threaded: Add support of OETestRunnerThreaded
The OETestRunnerThreaded overrides the run method of OETestRunner
it recieves a list of suites to be executed by a ThreadPool.

The new run method handles the ThreadPool creation and the
OETestResultThreaded fill.

[YOCTO #11450]

(From OE-Core rev: 48b7a407d692e6c49c41b16f2bd11e8c3f47a421)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-02 13:36:13 +01:00
Aníbal Limón
44285351f5 oeqa/core/threaded: Add OETestResultThreaded{,Internal} classes
The OETestResultThreadedInternal extends OETestResult to stores
results by Thread.

The OETestResultThreaded is a simple class that provides the
implementation of interfaces needed by outside like wasSuccesful,
stop, logSummary, logDetails.

[YOCTO #11450]

(From OE-Core rev: 8e71844fc4dd3fcc8a19f9d4c25aafb09c5525fe)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-02 13:36:13 +01:00
Aníbal Limón
ce422c7008 oeqa/core/threaded: Add OEStreamLoggerThreaded class
The OEStreamLoggerThreaded overrides OEStreamLogger to redirect
the PyUnit output to a logger.

Instead of log every line when comes the OEStreamLoggerThreaded
will buffer the PyUnit output and write everything at end of every
suite execution to don't have mixed suite outputs.

[YOCTO #11450]

(From OE-Core rev: 87d3e5b70c52e5c7439afe4af5aa002522043e81)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-02 13:36:13 +01:00
Aníbal Limón
c118f80f17 oeqa/core/threaded: Add new module with OETestLoaderThreaded
The threded module will implement Thread support into the OEQA
framework.

The OETestLoaderThreaded overrides discover to return a list of
suites every suite will be run by a separate Thread.

Some design considerations are:

- All the tests of a certain module needs to be run at one thread
  because unittest framework needs to keep track of setUp{Module,
Class,} and tearDown{Module, Class,}.

- Tests that depends on other needs to be run at the same thread
because OEQA framework look at the status of dependant test to
decide if skip or not, this constraint can be change in the future
but a sync mechanishm is needed to implement between the Threads.

[YOCTO #11450]

(From OE-Core rev: b4ae730ee1d6003ff005148f741270e2878de484)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-02 13:36:13 +01:00