summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/oetest.py
diff options
context:
space:
mode:
authorEd Bartosh <ed.bartosh@linux.intel.com>2016-04-18 15:27:24 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-04-18 16:28:22 +0100
commitecaf12ea5bf50ecef950f14a22e774e1d89aebb6 (patch)
treeedc27f91be72f41a37d3259d883099b45e86b462 /meta/lib/oeqa/oetest.py
parent4946ecfb42d71c35c1421061479731a4ea88f762 (diff)
downloadpoky-ecaf12ea5bf50ecef950f14a22e774e1d89aebb6.tar.gz
oetest: make console output more verbose
Added output of test runner to bitbake console output. bitbake <image> -c testimage now reports test progress to the console: NOTE: Executing RunQueue Tasks ... NOTE: recipe core-image-lsb-1.0-r0: task do_testimage: Started core-image-lsb-1.0-r0 do_testimage: test_ping (oeqa.runtime.ping.PingTest) ... ok core-image-lsb-1.0-r0 do_testimage: test_ssh (oeqa.runtime.ssh.SshTest) ... ok ... ---------------------------------------------------------------------- core-image-lsb-1.0-r0 do_testimage: Ran 38 tests in 785.100s core-image-lsb-1.0-r0 do_testimage: core-image-lsb-1.0-r0 do_testimage: OK (skipped=1) Adding more output to the console should also prevent autobuilder to kill long running tests as ab assumes that test is stuck if no console output produced by it for a long time. [YOCTO #8238] (From OE-Core rev: 06aa68138ec67623892221fbe9516bbb3795b48e) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/oetest.py')
-rw-r--r--meta/lib/oeqa/oetest.py10
1 files changed, 3 insertions, 7 deletions
diff --git a/meta/lib/oeqa/oetest.py b/meta/lib/oeqa/oetest.py
index 8eb84ed65d..3ed5bb8c2b 100644
--- a/meta/lib/oeqa/oetest.py
+++ b/meta/lib/oeqa/oetest.py
@@ -7,7 +7,7 @@
7 7
8# It also has some helper functions and it's responsible for actually starting the tests 8# It also has some helper functions and it's responsible for actually starting the tests
9 9
10import os, re, mmap 10import os, re, mmap, sys
11import unittest 11import unittest
12import inspect 12import inspect
13import subprocess 13import subprocess
@@ -326,12 +326,8 @@ class TestContext(object):
326 logger.info("Filter test cases by tags: %s" % self.tagexp) 326 logger.info("Filter test cases by tags: %s" % self.tagexp)
327 logger.info("Found %s tests" % self.suite.countTestCases()) 327 logger.info("Found %s tests" % self.suite.countTestCases())
328 runner = unittest.TextTestRunner(verbosity=2) 328 runner = unittest.TextTestRunner(verbosity=2)
329 try: 329 if 'bb' in sys.modules:
330 if bb.msg.loggerDefaultVerbose: 330 runner.stream.write = custom_verbose
331 runner.stream.write = custom_verbose
332 except NameError:
333 # Not in bb environment?
334 pass
335 331
336 return runner.run(self.suite) 332 return runner.run(self.suite)
337 333