Trace logs

In this chapter, we’ll explain how trace logs generation works, what the trace logs look like when opened in Microsoft Excel (though you can open them in basically any spreadsheet or database program), and what the different headers in the files mean.

In this chapter

    Trace log creation

    Whenever you start a test run with any tracer active, Ranorex Studio will generate four timestamped logs (CSV format) in the configured output folder (default: %MyDocuments%RanorexTraceLogs):

    The log for all Input tracers

    The log for the Misc tracer

    The log for the All tracer

    The log for the Repository tracer

    During the test run, Ranorex Studio does the following:

    • It checks which tracer is active and fills its log with the relevant data.
    • It always also enters this data into the log for the All tracer in a more concise format.

    For example, if the Repository tracer is active, Ranorex Studio fills the Repository log and the All log with data. The other logs remain empty.

    When you start a new test run with a tracer active, this process is repeated with new timestamped logs.

    Open trace logs

    Ranorex Studio generates trace logs in the CSV format with commas as the delimiter. You can open them with virtually any spreadsheet or database program. We’ll use Microsoft Excel for our explanations.

    Normally, you shouldn’t need to do anything for the logs to display correctly in a spreadsheet or database program. In some cases, however, you may need to import them manually and/or set the delimiter.

    For example, all data may be in column A when you open a log in Microsoft Excel.

    To fix this:

    Select the entire column A.

    In the menu bar, click Data > Text to Columns.

    In the dialog that opens, click Delimited > Next, check Comma, and click Finish.

    Trace log headers

    The logs are created as CSV files with a header section. The headers specify what information was collected. The different logs have different headers, but they also share some. Below, you’ll find an explanation of the headers in each log.

    There are three headers that you’ll find in all logs:

    TimeStamp: The time an event (search for a repository item, action execution, etc.) started.

    Module: The module the event occurred in.

    TotalTime: The total time an event took in milliseconds.

    Repository tracer

    RepoItem
    The full name of the searched repository item.

    RepoItemId
    The ID of the searched repository item.

    RepoItemPath
    The full RanoreXPath of the searched repository item.

    EffectiveTimeout
    The effective timeout in ms, as set in the properties of the repository item.

    TimesSearched
    How often Ranorex Studio attempted to find the repository item within the defined effective timeout.

    LastSearchTime
    How long the last successful search took in milliseconds.

    Found
    Whether the item was found (TRUE) or not (FALSE).

    MouseInput, KeyboardInput, AllInput

    RepoItem
    The full name of the searched repository item.

    RepoItemId
    The ID of the searched repository item.

    Device
    Whether the action is a mouse or a keyboard action.

    InputType
    The specific type of mouse or keyboard input. This can be:

    • for mouse: click, move
    • for keyboard: sequence, press (Key shortcut press action in the recording module)

    Other mouse/keyboard actions are practically instantaneous and therefore not collected.

    RepeatCount
    How often the action was performed.

    NominalDuration
    The nominal duration as set in the properties of the action.

    Misc

    EventType
    The type of event that occurred. This can can be:

    • fixed-delay: A delay action.
    • datasource-load: Ranorex Studio loads a data source, e.g. an Excel file.
    • proc-start: A Run application action.
    • wait-proc-close: A Close application action.
    • screenshot-trace: Tracing screenshots (Foreground/Background corresponds to the setting in the Report tab in the test suite properties).
    • report-slow: Various reporting events that take longer than 10 ms.
    • report-test-text-slow and report-test-data-slow: Ranorex Studio is busy creating the report and performance tracing is on hold.
    • other: Events not native to Ranorex Studio, e.g. user code actions.

    Details
    More information relating to the EventType.

    All

    TestContainer
    The test container the event occurred in.

    EventType
    The type of event that occurred. This can be:

    • fixed-delay: A delay action.
    • datasource-load: Ranorex Studio loads a data source, e.g. an Excel file.
    • proc-start: A Run application action.
    • wait-proc-close: A Close application action.
    • screenshot-trace: Tracing screenshots (Foreground/Background corresponds to the setting in the Report tab in the test suite properties).
    • report-slow: Various reporting events that take longer than 10 ms.
    • report-test-text-slow and report-test-data-slow: Ranorex Studio is busy creating the report and performance tracing is on hold.
    • other: Events not native to Ranorex Studio, e.g. user code actions.

    Details
    More information relating to the EventType.