Previous Topic Next topic Print topic


Test Runner Syntax Options

Use the following syntax from the Visual COBOL command line or shell prompt to run a test suite.

At the prompt, enter:

test-runner [options] [test-suite] 

where:

test-runner
The name of the executable that will run the test suite, and then produce the test results. It can be one of:
  • mfurun (Windows)
  • cobmfurun32[_t](UNIX)
  • cobmfurun64[_t] (UNIX)

The optional _t runs the test suite in the multi-threaded run-time system.

options

The options that apply to the test run. These are optional, and you can apply one or more of the following:

-testcase:testcase-name
Only run the specified test case from the test suite; all other test cases are skipped. Not set by default.
-ignore-return-code:{true|false}
When set to true, the return-code indicating a test pass or fail is ignored, and the test continues running. The default is false.
-verbose:{true|false}
Displays verbose output to the screen. The default is true.
-process:{single|separate}
Use a single process for the entire test run, or multiple separate processes (one for the test runner and one for each test case within the run). If you are using separate processes, the parent test runner process can log errors and continue with the test run in the event of a test case failure. The default is separate.
-isolate:{true|false}
Isolates each test case, so that any resources shared between test cases start from their correct initial state for each test case. The default is true.
-report{printfile|noprintfile|junit|nojunit|}...
Outputs the test results to a .txt file (printfile option) or .xml file (junit option). The default is to produce a .txt file.
-reportfile:filename
Changes the name of the .txt report file. It defaults to <test suite-name>-report.txt.
-junit-packname:package-name
Packages the JUnit formatted .xml files under package-name. Not set by default.
-outdir:directory
Specifies a directory for the reports. If not specified, the reports are created in the directory in which the tests were run.
-jenkins-ci
Enables support for producing test results that will be used on a Jenkins CI server.
-jenkins-ci:junit-attachments
Enables support for producing test results that will be used on a Jenkins CI server, and also enables the Jenkins plugin for JUnit formatted results.
-jit:{core|debug}
Produces a core dump file or invokes just-in-time debugging when a test case errors.
Note: This option has no effect when asserting a test failure.
-generate-mfu filename
Produces a skeleton test fixture file (.mfu file) from the test cases within filename (a .dll file or .so file).
Note: An .mfu file of the same name must not already exist; otherwise the new .mfu file will not be created.
test-suite
A COBOL program compiled to .dll(Windows) or .so (UNIX), or an .mfu batch file.
Previous Topic Next topic Print topic