diff options
author | shwetha <shwetha.h.panduranga@redhat.com> | 2012-03-06 16:14:34 +0530 |
---|---|---|
committer | shwetha <shwetha.h.panduranga@redhat.com> | 2012-03-06 16:15:29 +0530 |
commit | 4a0b5f9d0e0266c8c67b5faa76599fc78a247437 (patch) | |
tree | f50ab57eb319f5ef18d08c8ae0db779a5b4d2287 /atfexecute.py | |
parent | 0c9076add5f357b4278c4720c37518280a13e43e (diff) |
Adding libraries to suffix timestamps to the summarylog and detaillog files
Change-Id: I853981b0de99372509649360a67e8c4cca24b415
Signed-off-by: shwetha <shwetha.h.panduranga@redhat.com>
Diffstat (limited to 'atfexecute.py')
-rw-r--r-- | atfexecute.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/atfexecute.py b/atfexecute.py index c793cbb..bf5a9db 100644 --- a/atfexecute.py +++ b/atfexecute.py @@ -5,6 +5,7 @@ import sys import imp from atfglobals import GlobalObj import pdb +import atfutils def _execute_testunit(testunitname): """ @@ -20,8 +21,8 @@ def _execute_testunit(testunitname): testunits_maindir = GlobalObj.testunits_maindir testunit_mainmodule = GlobalObj.testunit_mainmodule testunit_abspath = os.path.join(atfdir, testunits_maindir, testunitname) - - + + _file, path, description = imp.find_module(testunit_mainmodule, [testunit_abspath]) @@ -38,9 +39,11 @@ def _execute_testunit(testunitname): (testunit_mainmodule, testunitname)) logger.error("%s execution Failed" % testunitname) return_status = 0 - + else: detaillog_abspath = os.path.join(testunit_abspath, detaillog_file) + if GlobalObj.attach_timestamp is 'yes': + detaillog_abspath = atfutils.attach_timestamp(detaillog_abspath) if logger.addDetaillogHandler(detaillog_abspath, detaillog_level): logger.error("Unbale to add Detaillog Handler for testunit: %s" % testunitname) |