Logging

GuineaPig saves the diagnostics and error messages it generates when running a test. By default, the messages are saved to file 'session.log' in the test directory. If the file already exists, new information will be appended to the file (does not overwrite an existing log file). Also the verbosity level of messages that is included can be selected.

The logging (verbosity) level is set with the logLevel parameter in the test configuration file. For example:

   # Verobosity level
   logLevel:   debug
The log levels available are: silent, brief, normal, verbose, veryverbose, and debug (in order of from least verbose (silent) to most verbose (debug)). The default is normal. Level silent only prints error messages.

It is also possible to define a different logging level for console output with the logConsoleLevel parameter. For example:

   # Log level for file
   logLevel:         debug
   # Log level for console
   logConsoleLevel:  brief
In this example all messages are saved to a file but only brief logging is printed on console. The console logging level must not be more verbose than file logging level.

The file where to save the log can be selected with the logFile parameter:

   # File where to log
   logFile:   session.log
The file name is relative to test directory unless absolute path is used. In the future, logging may be possible to automatically to use a session ID based log file name.
· Tests index · Manual index ·

Last modified: Tue Jul 27 12:46:52 EEST 1999