verbose
)Including the verbose
command and optional monitoring options in a run command allows the user to monitor test progress from the command line. This command uses stdout
to display the specified levels of monitoring test run progress. This monitoring function is not available in the GUI.
The monitoring options are specified in the command
line as a comma-separated list following the -verbose
option.
A colon is used to separate the -verbose
command from the options.
Ordering and capitalization within the list are ignored. Whitespace within
the list is prohibited.
If you do not specify a level, the progress
option is automatically used.
> javatest -verbose:
Monitor option [Setup commands] ... -runtests
...
See About the Command-Line Examples for a description of the use of > javatest in the example.
See Examples of Monitoring Output for detailed examples of the command line.
The following table describes monitoring options specified in the command line.
Option | Description |
---|---|
commands |
Traces the individual JavaTest harness commands as they are executed. This includes options given on the command line, commands given in command strings, and commands given in command files. |
no-date |
Do not prefix entries with the data and time stamp. Normally, each logical line of output will print the month, day, hour, minute and second. |
non-pass |
Print non-passing (error, fail) test names and their status string. The status string includes the status (error, fail) and the reason for the failure/error. |
max |
Output the maximum possible amount of output. This includes all the options
which are individually available. If this option is present, only the no-date and quiet flags
have any additional effect. |
quiet |
Suppress any output from the verbose system. It may be useful to temporarily
deactivate monitoring while debugging, without removing other levels coded
into a script. -verbose:stop,progress,quiet results in no
output, as does -verbose:quiet,stop,progress . This option
takes precedence over all other options. It does not suppress the pass/fail/error
statistics printed at the end of the test run. |
start |
Prints the test name when it goes into the the harness' engine for execution. Note: On some test suites, this may only indicate that the test has been handed to the plug-in framework, not that it is actually executing. |
stop
|
Prints the test name and status string (see non-pass ) when
a test result is received by the harness. |
progress |
Prints a progress summary, which indicates pass/fail/error/not-run numbers.
If any of the max, non-pass, stop, or stop options
were specified, each summary may be printed on it's own line. If not, the
summary will be updated on the current line. The progress information is
printed/updated each time a test result is reported to the harness. |
The following are examples of monitoring commands and their resulting command line output.
> java -jar lib/javatest.jar -verbose -open foo.jti -runtests 14:21:31 Sept 14 - Harness starting test run with configuration "foo". 14:24:33 Sept 14 - Pass: 12 Fail: 0 Error: 1 Not-Run: 33 14:24:30 Sept 14 - Finished executing all tests, wait for cleanup... 14:26:31 Sept 14 - Harness finished test run.
start
monitoring output:
> java -jar lib/javatest.jar -verbose:start -open foo.jti -runtests 14:21:31 Sept 14 - Harness starting test run with configuration "foo". 14:24:39 Sept 14 - Running foo/bar/index#id1 14:24:30 Sept 14 - Test run stopped, due to failures, errors, user request. Wait for cleanup... 14:26:31 Sept 14 - Harness finished test run.
start
and stop
monitoring output:
> java -jar lib/javatest.jar -verbose:start,stop -open foo.jti -runtests 14:21:31 Sept 14 - Harness starting test run with configuration "foo". 14:24:31 Sept 14 - Running foo/bar/index#id1 14:24:32 Sept 14 - Finished foo/bar/index#id1 Fail. Invalid index did not throw exception. 14:26:33 Sept 14 - Running foo/bar/index#id2 14:27:34 Sept 14 - Finished foo/bar/index#id2 Pass. 14:28:35 Sept 14 - Running foo/bar/index#id3 14:29:36 Sept 14 - Finished foo/bar/index#id3 Error. Cannot invoke JVM. 14:30:30 Sept 14 - Finished executing all tests, wait for cleanup... 14:30:31 Sept 14 - Harness finished test run.
no-date
, start
, and stop
monitoring output:
> java -jar lib/javatest.jar -verbose:no-date,start,stop -open foo.jti -runtests Harness starting test run with configuration "foo". Running foo/bar/index#id1 Finished foo/bar/index#id1 Fail. Invalid index did not throw exception. Running foo/bar/index#id2 Finished foo/bar/index#id2 Pass. Running foo/bar/index#id3 Finished foo/bar/index#id3 Error. Cannot invoke JVM. Test run stopped, due to failures, errors, user request. Wait for cleanup... Harness finished test run.
non-pass
monitoring output:
> java -jar lib/javatest.jar -verbose:non-pass -open foo.jti -runtests Harness starting test run with configuration "foo". Running foo/bar/index#id1 Finished foo/bar/index#id1 Fail. Invalid index did not throw exception. Running foo/bar/index#id2 Finished foo/bar/index#id2 Pass. Test run stopped, due to failures, errors, user request. Wait for cleanup... Harness finished test run.
progress
and non-pass
monitoring output:
> java -jar lib/javatest.jar -verbose:progress,non-pass -open foo.jti -runtests 14:23:39 Sept 14 - Harness starting test run with configuration "foo". 14:24:39 Sept 14 - Pass: 12 Fail: 0 Error: 0 Not-Run: 33 14:25:32 Sept 14 - Finished foo/bar/index#id1 Fail. Invalid index did not throw exception. 14:26:39 Sept 14 - Pass: 12 Fail: 1 Error: 0 Not-Run: 32 14:27:39 Sept 14 - Pass: 12 Fail: 1 Error: 0 Not-Run: 32 14:30:36 Sept 14 - Finished foo/bar/index#id3 Error. Cannot invoke JVM. 14:32:39 Sept 14 - Pass: 12 Fail: 1 Error: 1 Not-Run: 31 14:33:01 Sept 14 - Test run stopped, due to failures, errors, user request. Wait for cleanup... 14:33:10 Sept 14 - Harness finished test run.
no-date
and max
monitoring output:
> java -jar lib/javatest.jar -verbose:no-date,max -open foo.jti -runtests Harness starting test run with configuration "foo". Running foo/bar/index#id1 Finished foo/bar/index#id1 Fail. Invalid index did not throw exception. Pass: 0 Fail: 1 Error: 0 Not-Run: 33 Running foo/bar/index#id2 Finished foo/bar/index#id2 Pass. Pass: 1 Fail: 1 Error: 0 Not-Run: 32 Test run stopped, due to failures, errors, user request. Wait for cleanup... Harness finished test run.