diff --git a/script/testcommons.py b/script/testcommons.py index 81d6b50..c7eb006 100644 --- a/script/testcommons.py +++ b/script/testcommons.py @@ -2,6 +2,7 @@ global print_log, sendFeedback, sys, inspect, os, traceback import sys, inspect, os, traceback def print_log(testName, DEVICE, text): + import time time.ctime() now = time.strftime('%Y.%m.%d %H:%M:%S') print now + ' ' + DEVICE + ' - ' + testName + ': ' + str(text) diff --git a/script/tests/tests/PS Tests/power-supply-A/power-supply-A.py b/script/tests/tests/PS Tests/power-supply-A/power-supply-A.py index ba8170a..6cb2bdc 100644 --- a/script/tests/tests/PS Tests/power-supply-A/power-supply-A.py +++ b/script/tests/tests/PS Tests/power-supply-A/power-supply-A.py @@ -1,10 +1,12 @@ ######################################### ###### DO NOT MODIFY THE CODE BELOW ##### ######################################### -global print_log, sendFeedback, sys, inspect, os, traceback global testcommons import testcommons +def print_log(testName, DEVICE, text): + testcommons.print_log(testName, DEVICE, text) + def startTest(testName, DEVICE, params): #get the path of this script import inspect