Running a test or schedule from a command line
You can run a test or schedule without opening Rational® Performance Tester by using the command-line interface (CLI).
Before you begin
-
You must have read and been familiar with command line parameters. See Command-line parameters.
-
You must have completed the following tasks:
-
Recorded the tests in Rational® Performance Tester.
-
Set the Web Reports preferences in Rational® Performance Tester to view the reports remotely. See Accessing reports remotely.
-
Optional: Created a configuration file to use the -configfile parameter. See Creating a command-line config file.
-
Optional: Added password of encrypted datasets to secure storage. See Activating secure storage of dataset passwords.
-
Closed Rational® Performance Tester.
-
About this task
The command-line syntax with the checkmark_perf.jpg parameters is as follows:
cmdline -workspace <workspace_full_path> -project <proj_name or proj_relative_path> -eclipsehome <eclipse_full_path> -plugins <plugin_full_path> -schedule <sched_name or sched_rel_path> -suite <suite_name or suite_relative_path> -importzip <full_path_to_zip_file> -varfile <variable_file_full_path> -configfile <file_full_path> -results <result_file> -overwrite <"true" | "false"> -quiet -users <number_of_users> -vmargs <JVM_args> -rate <RateRunnerGroupName=iterationNumber1/duration, iterationNumber2/duration> -duration <Stage1=durationOfStage; Stage2=durationOfStage> -execsummaryreport <id_of_report> -stdout -publish <serverURL>#project.name=<projectName>&teamspace.name=<name_of_the _teamspace> -publish_for <ALL,PASS,FAIL,ERROR, INCONCLUSIVE> -labels <labelname1, labelname2> -exportlog <log_full_path> -exportstats <local_dir_path> -exportstatshtml <local_dir_path> -exportstatsformat <name of the file format> -compare <"result_path1, result_path2"> -exportstatreportlist <stats_list> -usercomments <"any user comment"> -publishreports <"STATS, TESTLOG"> -swapdatsets <existing_dataset_file_path:new_dataset_file-path> -timerange <"all, 5 Users, 10 Users"> -history <jaeger,testlog,null> -overridermlabels <"rmlabelname1,rmlabelname2"> -ignoreunhealthytranscations <"true" | "false"> -execsummary <path_to_local_dir>
Procedure
- Open the command prompt.
-
Run the following command to change the directory to the
cmdline directory:
cd <cmdline_directory_path>
For example,cd C:\Program Files\IBM\SDP\cmdline
Based on the operating system that you used to install Rational® Performance Tester, you can locate the cmdline directory as follows:
Operating system The default path to the directory Windows® C:\Program Files\IBM\SDP\cmdline Linux™ /opt/IBM/SDP/cmdline Mac /Application/IBM/SDP/cmdline -
Run the following command to run the test:
cmdline -workspace workspace_full_path -project proj_rel_path -suite suite_name or suite_rel_path
For example,
ORcmdline -workspace "C:/Users/IBM/rationalsdp/workspace" -project "/myproj/proj123" -suite "test1.testsuite"
cmdline -workspace "C:/Users/IBM/rationalsdp/workspace" -project "/myproj/proj123" -suite "Tests/test1.testsuite"
Note: You can add an additional parameter to the preceding command according to your testing requirements and then run the test.The test run starts and the status is displayed on CLI.
Results
What to do next
If you have published test results to Rational® Test Automation Server, then refer to the Rational® Test Automation Server documentation.