diff options
author | Yan <yanxk.fnst@fujitsu.com> | 2023-04-26 09:53:43 +0800 |
---|---|---|
committer | Jan-Simon Moeller <jsmoeller@linuxfoundation.org> | 2023-04-27 09:54:58 +0000 |
commit | 72ef06848743500bbc30d5209cbb038e24afa652 (patch) | |
tree | 2f408d44b478ce96141a36368f50820f8f5b913c | |
parent | 600cd4ebcb67e5d918290749852bda8ad1c090a5 (diff) |
agl-test-framework: add ptest babeltrace
Add ptest babeltrace in agl-test-framework.
Bug-AGL: SPEC-4753
Signed-off-by: Yan <yanxk.fnst@fujitsu.com>
Change-Id: I8ef9cfb2dc37f647f0417400bfa715e662dbd610
-rw-r--r-- | tests/babeltrace/__init__.py | 1 | ||||
-rw-r--r-- | tests/babeltrace/run_tests.py | 27 |
2 files changed, 28 insertions, 0 deletions
diff --git a/tests/babeltrace/__init__.py b/tests/babeltrace/__init__.py new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/tests/babeltrace/__init__.py @@ -0,0 +1 @@ + diff --git a/tests/babeltrace/run_tests.py b/tests/babeltrace/run_tests.py new file mode 100644 index 0000000..77b7f16 --- /dev/null +++ b/tests/babeltrace/run_tests.py @@ -0,0 +1,27 @@ +import pytest +import plugins.agl_test_log as log +from plugins.agl_test_ptest_base import PTESTBase + +class BabeltraceBase(PTESTBase): + def __init__(self): + super().__init__(test_name="babeltrace") + + def log_process(self): + log_file = self.get_logfile() + self.case_info_list = log.log_process_gnu(log_file) + +instance = BabeltraceBase() +instance.run_ptest() + +@pytest.fixture(scope='module') +def testbase(): + yield instance + #package log files and make report file + instance.log_report() + +@pytest.mark.parametrize('case_name', instance.case_info_list.keys()) +def test_babeltrace(testbase: BabeltraceBase, case_name): + testbase.run_case(case_name) + +if __name__ == '__main__': + pytest.main("-s run_tests") |