oeqa.buildperf: implement BuildPerfTestRunner class

The new class is responsible for actually running the tests and
processing their results. This commit also adds a decorator function for
adding new tests. No automatic test discovery, at least yet.

(From OE-Core rev: bf90aecb7e150d6bfac7240286c797b79d26528b)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Markus Lehtonen
2016-05-11 14:42:32 +03:00
committed by Richard Purdie
parent 6512d6956b
commit 1d88659ef6
3 changed files with 57 additions and 3 deletions

View File

@@ -18,11 +18,12 @@ import argparse
import logging
import os
import sys
from datetime import datetime
sys.path.insert(0, os.path.dirname(os.path.realpath(__file__)) + '/lib')
import scriptpath
scriptpath.add_oe_lib_path()
from oeqa.buildperf import KernelDropCaches
from oeqa.buildperf import BuildPerfTestRunner, KernelDropCaches
from oeqa.utils.commands import runCmd
@@ -75,7 +76,12 @@ def main(argv=None):
# Check our capability to drop caches and ask pass if needed
KernelDropCaches.check()
return 0
# Run actual tests
out_dir = 'results-{}'.format(datetime.now().strftime('%Y%m%d%H%M%S'))
runner = BuildPerfTestRunner(out_dir)
ret = runner.run_tests()
return ret
if __name__ == '__main__':