Debugging scenario failure with GUI logs

A guilog generated when a scenario failure occurs can help you debug.

A scenario failure stops the execution of the test. You can, however, specify that the GGC generates guilog files at the end of the test to use for debugging.

Include the --guilog-as-error option in the Java or BDL command that runs the test scenario to generate the guilogs.

In this example, the option is added to the command that runs a Java test scenario against an application running on the GAS:
ggcadmin ua --guilog-on-error --url https://myserver:6394/ua/r/price --scenario myscenario
In this example, the option is added to the command that runs a Genero BDL test scenario against an application running on the GAS:
fglrun price_sample.42m ua --url http://localhost:6394/ua/r/price --guilog-on-error
With either example, if the GGC fails the scenario, it stops the test and writes two guilog files. The file names are in this format:
prefix-id.ext
Where:
  • prefix is by default "ggc-ua" or "ggc-tcp" depending on the client used for the test.
    Tip:

    There is an option to set the prefix with the --guilog-prefix option.

  • id is a string generated by the GGC
  • ext is the file extension, which is either guilog or guiend.

    The file with the .guilog extension contains the full AUI exchanges of the session. The file with the .guiend extension contains only the state of the AUI on failure. See Replaying the guilogs.

Look for files like these in your current working directory:

ggc-ua-131c38a25b02860be212172c72448e78.guiend
ggc-ua-131c38a25b02860be212172c72448e78.guilog

Tip:

You can specify a directory for these files with the option --guilog-directory

Replaying the guilogs

The .guilog file contains the complete session up to the point of failure. The .guiend file contains only the AUI tree at the time of the failure. When replaying it, you can see the last page displayed showing the state of the application when it failed. In most cases this may be sufficient to identify where the test failed. For example, if the VM raised an error popup, it will be displayed. Otherwise, the guilog file may be used. When replaying it, you can step through the AUI exchanges up to the point of when the test failed.

The .guilog or .guiend files can be replayed using the runtime command with the --run-guilog option, for example:
fglrun --run-guilog ggc-ua-131c38a25b02860be212172c72448e78.guilog 
Note:

In order to use the --run-guilog option, the front-end must be started and listening for direct connections.

For more information on using the --run-guilog command and debugging, see the Front-end protocol logging page in Genero Business Development Language User Guide.