mirror of
https://git.yoctoproject.org/poky
synced 2026-04-19 15:32:13 +02:00
oeqa/runtime/ptest: Ensure OOM errors are logged
Currently processed being killed by the OOM killer may not be spotted by ptest-runner. After we complete the tests, check the logs and report if there were any. This ensures the user is aware of OOM conditions affecting the ptest results. (From OE-Core rev: 20a441d53817f80e0ce1597e77f6e794422ac49a) (From OE-Core rev: f922970b119849bcdd7f7df74bd2029816ff637c) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
@@ -70,5 +70,13 @@ class PtestRunnerTest(OERuntimeTestCase):
|
||||
if failed_testcases:
|
||||
failed_tests[section] = failed_testcases
|
||||
|
||||
failmsg = ""
|
||||
status, output = self.target.run('dmesg | grep "Killed process"', 0)
|
||||
if output:
|
||||
failmsg = "ERROR: Processes were killed by the OOM Killer:\n%s\n" % output
|
||||
|
||||
if failed_tests:
|
||||
self.fail("Failed ptests:\n%s" % pprint.pformat(failed_tests))
|
||||
failmsg = failmsg + "Failed ptests:\n%s" % pprint.pformat(failed_tests)
|
||||
|
||||
if failmsg:
|
||||
self.fail(failmsg)
|
||||
|
||||
Reference in New Issue
Block a user