Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-37609

Unable to identify which test function is taking too much time to run

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 5.3.0
    • 5.3.0
    • Testing: qtestlib
    • None
    • BlackBerry 10
    • qtdeclarative 3ce2063cfa36a4165445c6e41a4add198a78aa06 (stable, 19.3.2014, 5.3)

    Description

      The warning shown when QTest::qSleep() is more than 50% off is not tied to any test function in particular. This warning was introduced by https://codereview.qt-project.org/80695

      The problem can be reproduced most of the time (at least on a BlackBerry Z10 device) by running:

      • ./tst_qquickcanvasitem -o -,txt -o tst_qquickcanvasitem.xml,xml

      the plain text output looks like:

      PASS   : qquickcanvasitem::pattern::cleanupTestCase()
      WARNING: qquickcanvasitem::UnknownTestFunc() QTest::qSleep() should have taken 10000000ns, but actually took 24427615ns!
         Loc: [qtestcase.cpp(2884)]
      PASS   : qquickcanvasitem::pixel::initTestCase()
      

      and the xml output looks like:

      <TestFunction name="pattern::cleanupTestCase">
      <Incident type="pass" file="" line="0" />
          <Duration msecs="105.662955"/>
      </TestFunction>
      <Message type="warn" file="qtestcase.cpp" line="2884">
          <Description><![CDATA[QTest::qSleep() should have taken 10000000ns, but actually took 24427615ns!]]></Description>
      </Message>
      <TestFunction name="pixel::initTestCase">
      <Incident type="pass" file="" line="0" />
          <Duration msecs="1.000000"/>
      </TestFunction>
      

      which does not specify which test function took more time during QTest:qSleep()

      Attachments

        For Gerrit Dashboard: QTBUG-37609
        # Subject Branch Project Status CR V

        Activity

          People

            ulherman Ulf Hermann
            seahumad [BB] Sergio Ahumada (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes