Closedown

This commit is contained in:
boccioli_m
2017-08-29 11:22:34 +02:00
parent 21e1e7264f
commit 55207ec27f
3 changed files with 10 additions and 5 deletions

View File

@@ -72,7 +72,7 @@ class TestingTool:
"""
import time
time.ctime()
now = time.strftime('---%Y.%m.%d %H:%M:%S')
now = time.strftime('%Y.%m.%d %H:%M:%S')
logText = self.deviceName + ' - ' + self.testName + ': ' + str(text)
print now + ' ' + logText
try:
@@ -87,13 +87,17 @@ class TestingTool:
print now + ' ' + self.deviceName + ' - ' + self.testName + ': ' + 'cannot write Log in Data'
def printParams(self, params):
def printParams(self):
"""
Print/log the pshell parameters
params = the JSON object with the parameters passed by pshell
"""
columnsFormat = '{0:10} {1:10} {2}'
self.log(columnsFormat.format("cedccewc", "23", "ewfe erfgerf ref erf"))
self.log(columnsFormat.format("Parameter", "Value", "Description"))
for param in self.testParams:
self.log(columnsFormat.format(self.testParams[param],
self.testParams[param].value,
self.testParams[param].description))
def sendFeedback(self, returnString, testPassed):

View File

@@ -1,5 +1,5 @@
#TestingList for pshell: configuration properties
#Tue Aug 29 11:16:44 CEST 2017
#Tue Aug 29 11:21:12 CEST 2017
customPanel=
showEnabledTestsOnly=true
listFilter=test-bx84

View File

@@ -69,7 +69,8 @@ def startTest(testName, DEVICE, params):
# test.log("Example - Device name: " + test.getDeviceName() )
try:
test.log("Running test with the following parameters:")
test.printParams(params)
test.log(params)
test.printParams()
# If present, use the parameters here below for your test script.
# These parameters were automatically generated: you might need to change the casting.
delay = float(test.getParam('delay')) ; centre = float(test.getParam('centre')) ; moveAround = float(test.getParam('moveAround')) ; steps = float(test.getParam('steps')) ;