This function checks a return code against an expected return code return code received from command the output of the result the expected return code 'RC=%s, Result=Ok' % (returncode) 'RC=%s, Result=%s' % (returncode,result) 'RC=%s, Expected %s, Result=%s' % (returncode,expected,result) RC This function checks the return code against an expected return code for a testcase return code received from command the output of the result the expected return code 'SUCCESS: RC=%s, Expected %s, Result=%s' % (returncode,expected,result) 'ERROR : RC=%s, Expected %s, Result=%s' % (returncode,expected,result) This function checks the return string against an expected return substring for a testcase the substring expected from the command the return string received from command 'Found substring, %s, in the return string' % (expectedString) 'Did not find substring, %s, in the return string, %s' % (expectedString, returnString) This function checks the return string against an expected return substring that should not be present for a testcase the substring being tested from the command the return string received from command 'Did Not Find substring, %s, in the return string' % (testString) 'Found substring, %s, in the return string, %s' % (testString, returnString) This function simply searches a string for a substring the substring being tested from the command the return string received from command 'Did Not Find substring, %s, in the return string' % (testString) 'Found substring, %s, in the return string' % (testString) returnCode Checks that the ldap server is running Location of target host Pathname to installation root Number of iterations Number of seconds to wait between iterations Directory server hostname or IP address Directory server port number Bind DN Bind password { 'location' : mylocation, 'dsPath' : mypath, 'dsInstanceHost' : myhost , 'dsInstancePort' : myport , 'dsInstanceDn' : mydn , 'dsInstancePswd' : mypswd , 'dsScope' : 'base' , 'dsBaseDN' : 'cn=config' , 'dsFilter' : 'objectclass=*' , 'expectedRC' : 'noCheck' } { 'sleepForMilliSeconds' : noOfMilliSeconds } Sleep for number of milliseconds Location of target host Number of milliseconds to sleep '%s' % location 'delay' 'delay %i' % sleepForMilliSeconds { 'returncode' : RC , 'result' : STAFResult } Set OS related variables Name of host on which to retrieve variables '%s' % hostname 'var' 'get system var STAF/Config/OS/Name' 'OS Name= %s' % STAFResult STAFResult Pretty prints a banner at the start of a test. '' '****************************************************' '*** STARTING TEST CASE %s.' % STAXCurrentTestcase '***' Pretty prints a banner at the end of a test. '***' '*** ENDING TEST CASE %s.' % STAXCurrentTestcase '****************************************************' '' Performs all the preoperations for a test case Performs all the post operations for a test suite 'A signal (%s) was raised during this test case' % SignalRaised '## Test Verdict: FAIL ##' '## Test Verdict: PASS ##' Performs all the pre operations for a test suite '#### %s/%s suite preamble ####' % (ThisGroupName,ThisSuiteName) Performs all the post operations for a test suite '#### %s/%s suite postamble ####' % (ThisGroupName,ThisSuiteName) { 'starttime' : TestSuiteStartTime, 'endtime' : TestSuiteEndTime, 'tofile' : TestLogFile } Performs all the pre operations for a test group '##### %s group preamble #####' % ThisGroupName Performs all the post operations for a test group '##### %s group postamble #####' % ThisGroupName Queries the staf logs for the test case and write to file as text timestamp to start logging from timestamp to start logging to name of file to write the logs { 'location' : STAXServiceMachine, 'logname' : 'STAX_Job_%s_User' % STAXJobID, 'startfrom' : starttime, 'endat' : endtime } { 'queryresult' : STAFResult, 'logfile' : tofile } Process staf log query results and write them to a file result of the staf log query name of the log file to where results are written 'Creating test log %s' % logfile { 'location' : STAXServiceMachine, 'foldername' : NewLogDir } check the number of matching sub-string in a string the sub-string to check the main string where the search is done number of expected sub-string that must be in the main string '%s' % myMessage '%s' % myMessage myRC,myMessage