How do I add additional files to an execution result using the CLA?
Listed below is my "commandline.properties":
# Note to U.S. Government Users Restricted Rights:
# Use, duplication or disclosure restricted by GSA ADP Schedule
# Contract with IBM Corp.
###############################################################################
###
### Exit Code Properties
###
# The following properties are used to control the mapping of application exit codes to
# RQM result codes. Note that the number in the property value denotes the exit code
# number with the exception of '*' which denotes all non-specified exit codes. Note
# that no exit code should be repeated and repeating exit codes may map to an unexpected
# value.
com.ibm.rqm.commandline.exitcode.PASSED=0
com.ibm.rqm.commandline.exitcode.PASSED=1
com.ibm.rqm.commandline.exitcode.FAILED=*
com.ibm.rqm.commandline.exitcode.ERROR=40
com.ibm.rqm.commandline.exitcode.INCOMPLETE=41
com.ibm.rqm.commandline.exitcode.INCONCLUSIVE=42
com.ibm.rqm.commandline.exitcode.BLOCKED=43
com.ibm.rqm.commandline.exitcode.PARTIALLY_BLOCKED=44
com.ibm.rqm.commandline.exitcode.PERMANENTLY_FAILED=45
com.ibm.rqm.commandline.exitcode.DEFERRED=46
###
### Generic Command Line Properties
###
# Append default Java system properties to execution result record if this property
# is set to true
com.ibm.rqm.commandline.systemproperties=False
# Optionally define a property file that gets used to update the status of the running
# command line execution. This text file must be written in Java properties format with
# two properties that the command line adapter will read, "progress" property as an
# integer value between 0 - 99 and an optional "comment" property read as a string value.
#
# If this file exists when the command line execution process begins, it will be truncated
# to clear any previous values.
#
# An environment variable named "qm_ExecutionPropertiesFile" will be created in the
# command line execution process and initialized to the value specified.
#com.ibm.rqm.commandline.executionproperties=/home/ppos/adapters/execution.properties
# Define the set of executables that will be allowed to be run by an instance of this adapter. Any executable
# not in this list will be rejected and the execution result record updated to highlight the cause of the failure.
# Multiple executables may be specified as long as they are separated by a comma.
#com.ibm.rqm.commandline.allowed_executables=first.bat,second.exe,third
# Set the maximum size (in megabytes) that is allowed for files attached to the execution result.
com.ibm.rqm.adapter.resultAttachmentsFile.maxfilesize=50
###
### Properties Added to Execution Result
###
# All properties that do not start with "com.ibm.rqm." are simply appended to the execution
# result file. Note that commandline.properties is read only once at adapter startup.
# To dynamically add properties to an Execution Result at runtime, append them to the file specified by
# the environment variable qm_CustomPropertiesFile.
#application_under_test=undefined
#build_id=undefined
#application_database=db2
importLog=/home/ppos/qfscripts/logs/report.html
Any help is greatly appreciated.
2 answers
Comments
Nope Linux
Are you running shell script?
This is the script that executes the test using the automation tool QFtest:
qftest -batch -calldaemon -daemonhost reg04.4999.menards.net -daemonport 1234 -verbose tests -runlog /home/ppos/qfscripts/logs/+b -suitedir /home/ppos/qfscripts AutomatedCases.qft#"Master.$1"
sleep 5
qftest -batch -genreport -report.html /home/ppos/qfscripts/logs/ -runlogdir /home/ppos/qfscripts/logs/ /home/ppos/qfscripts/logs/AutomatedCases_Master.$1.qrz
cp ./AutomatedCases_Master.$1.html ./report.html
I am assuming that the entry in the commandline.properties: importLog=/home/ppos/qfscripts/logs/report.html; would indicte to the CLA that the file named "report.html" would be uploaded.
Is there an equivalant Linux command to: "ECHO myLogFile=C:/temp/rqmupload.log >> "%qm_AttachmentsFile%"?
Figured it out:
echo "testResults=\/home\/ppos\/qfscripts\/logs\/report.html" >> $qm_AttachmentsFile
echo "testResultsXML=\/home\/ppos\/qfscripts\/logs\/report.xml" >> $qm_AttachmentsFile
echo "testResultImages=\/home\/ppos\/qfscripts\/logs\/report.tar" >> $qm_AttachmentsFile
But now, I get "Failed" result returned. Any Ideas?
Steve,
I am computing the result based on data from an html file and ending the script with either a "exit 0" or "exit 1"
I am returning an "exit" code from my script that the CLA executes. I am not setting any values.
Please could you assist me with directing my execution result to a log file that is created after every test. I have successfully run the test via CLA, and from the configs above, I can see that you point your .bat file to an exact log file. But how would this be done if a new folder is created with the log inside after every test run?
Thanks
Leesen