539553a572
Add an enumeration for system-out and alog element for it. Redirect the messages types that are not warnings/errors to this element. For compatibility, write it out only if it is not empty. Rename enumerations and members accordingly. [ChangeLog][QtTestLib] In JUnit XML, output that is not a warning/error is now logged under <system-out> instead of <system-err>. Fixes: QTBUG-86540 Change-Id: I55598eafa7dafa486ac5a8221029c332ff47413b Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
61 lines
2.9 KiB
XML
61 lines
2.9 KiB
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<testsuite name="tst_Warnings" timestamp="@TEST_START_TIME@" tests="6" failures="4" errors="17" time="@TEST_DURATION@">
|
|
<properties>
|
|
<property name="QTestVersion" value="@INSERT_QT_VERSION_HERE@"/>
|
|
<property name="QtVersion" value="@INSERT_QT_VERSION_HERE@"/>
|
|
<property name="QtBuild" value=""/>
|
|
</properties>
|
|
<testcase name="initTestCase" result="pass" time="@TEST_DURATION@"/>
|
|
<testcase name="testWarnings" result="pass" time="@TEST_DURATION@">
|
|
<!-- type="qwarn" message="Warning" -->
|
|
<!-- type="qwarn" message="Warning" -->
|
|
<!-- type="qdebug" message="Debug" -->
|
|
<!-- type="qdebug" message="Debug" -->
|
|
<!-- type="qinfo" message="Info" -->
|
|
<!-- type="qinfo" message="Info" -->
|
|
<!-- type="qdebug" message="Baba" -->
|
|
<!-- type="qdebug" message="Baba" -->
|
|
<!-- type="qdebug" message="Bubublabla" -->
|
|
<!-- type="qwarn" message="Babablabla" -->
|
|
</testcase>
|
|
<testcase name="testMissingWarnings" result="fail" time="@TEST_DURATION@">
|
|
<!-- type="info" message="Did not receive message: "Warning0"" -->
|
|
<!-- type="info" message="Did not receive message: "Warning1"" -->
|
|
<failure result="fail" message="Not all expected messages were received"/>
|
|
</testcase>
|
|
<testcase name="testMissingWarningsRegularExpression" result="fail" time="@TEST_DURATION@">
|
|
<!-- type="info" message="Did not receive any message matching: "Warning\s\d"" -->
|
|
<failure result="fail" message="Not all expected messages were received"/>
|
|
</testcase>
|
|
<testcase name="testMissingWarningsWithData" result="fail" time="@TEST_DURATION@">
|
|
<!-- type="info" message="Did not receive message: "Warning0"" tag="first row" -->
|
|
<!-- type="info" message="Did not receive message: "Warning1"" tag="first row" -->
|
|
<failure result="fail" message="Not all expected messages were received" tag="first row"/>
|
|
<!-- type="info" message="Did not receive message: "Warning0"" tag="second row" -->
|
|
<!-- type="info" message="Did not receive message: "Warning1"" tag="second row" -->
|
|
<failure result="fail" message="Not all expected messages were received" tag="second row"/>
|
|
</testcase>
|
|
<testcase name="cleanupTestCase" result="pass" time="@TEST_DURATION@"/>
|
|
<system-out>
|
|
<![CDATA[Debug]]>
|
|
<![CDATA[Debug]]>
|
|
<![CDATA[Info]]>
|
|
<![CDATA[Info]]>
|
|
<![CDATA[Baba]]>
|
|
<![CDATA[Baba]]>
|
|
<![CDATA[Bubublabla]]>
|
|
<![CDATA[Did not receive message: "Warning0"]]>
|
|
<![CDATA[Did not receive message: "Warning1"]]>
|
|
<![CDATA[Did not receive any message matching: "Warning\s\d"]]>
|
|
<![CDATA[Did not receive message: "Warning0"]]>
|
|
<![CDATA[Did not receive message: "Warning1"]]>
|
|
<![CDATA[Did not receive message: "Warning0"]]>
|
|
<![CDATA[Did not receive message: "Warning1"]]>
|
|
</system-out>
|
|
<system-err>
|
|
<![CDATA[Warning]]>
|
|
<![CDATA[Warning]]>
|
|
<![CDATA[Babablabla]]>
|
|
</system-err>
|
|
</testsuite>
|