A tool for further processing of Robot Framework output files.
statuschecker.py infile [outfile]
This tool processes Robot Framework output XML files and checks that test case statuses and messages are as expected. The main use case is post-processing output files got when testing Robot Framework test libraries using Robot Framework itself.
If an output file is not given, the input file is considered to be also an output file and it is edited in place.
By default, all test cases are expected to PASS and have no message. Changing the expected status to FAIL is done by having the word "FAIL" (in uppercase) somewhere in the test case documentation. The expected error message must then be given after "FAIL". The error message can also be specified as a regular expression by prefixing it with "REGEXP:". Having spaces between the status, the message or the possible "regexp" prefix is optional.
The expected keyword log messages can also be defined in the test case documentation using a syntax such as:
LOG x.y:z message
For example, the following documentation expects that the test case fails with the message Expected message, and in addition, the second log message of the first keyword is Log message:
FAIL: Expected failure LOG 1:2 Log message
The message index (the number after ":") is by default 1, so if you check the first log message of the given keyword, it may be omitted.