summaryrefslogtreecommitdiffstats
path: root/tests/qemu-iotests/testrunner.py
Commit message (Collapse)AuthorAgeFilesLines
* iotests: Fix -makecheck outputKevin Wolf2021-02-021-2/+4
| | | | | | | | | | | | | | | | | | | | For -makecheck, the old 'check' implementation skipped the output when starting a test. It only had the condensed output at the end of a test. testrunner.py prints the normal output when starting a test even for -makecheck. This output contains '\r' at the end so that it can be overwritten with the result at the end of the test. However, for -makecheck this is shorter output in a different format, so effectively we end up with garbled output that mixes both output forms. Revert to the old behaviour of only printing a message after the test had completed in -makecheck mode. Fixes: d74c754c924ca34e90b7c96ce2f5609d82c0e628 Signed-off-by: Kevin Wolf <kwolf@redhat.com> Message-Id: <20210201161024.127921-1-kwolf@redhat.com> Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* iotests: check: return 1 on failureVladimir Sementsov-Ogievskiy2021-02-021-1/+3
| | | | | | | | | | We should indicate failure by exit code, not only output. Reported-by: Peter Maydell Fixes: f203080bbd9f9e5b31041b1f2afcd6040c5aaec5 Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Message-Id: <20210201085041.3079-1-vsementsov@virtuozzo.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* iotests/testrunner: fix recognition of python testsVladimir Sementsov-Ogievskiy2021-01-291-1/+1
| | | | | | | | | | We should drop final '\n' before comparing with python3 shebang. Fixes: d74c754c924ca34e90b7c96ce2f5609d82c0e628 Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Message-Id: <20210129090616.84145-1-vsementsov@virtuozzo.com> Tested-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* iotests: add testrunner.pyVladimir Sementsov-Ogievskiy2021-01-271-0/+367
Add TestRunner class, which will run tests in a new python iotests running framework. There are some differences with current ./check behavior, most significant are: - Consider all tests self-executable, just run them, don't run python by hand. - Elapsed time is cached in json file - Elapsed time precision increased a bit - Instead of using "diff -w" which ignores all whitespace differences, manually strip whitespace at line end then use python difflib, which no longer ignores spacing mid-line Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Message-Id: <20210125185056.129513-5-vsementsov@virtuozzo.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>