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

[autotests] Tests using QSignalSpy should call QVERIFY(spy.isValid());

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P3: Somewhat important P3: Somewhat important
    • 5.0.0
    • 5.0.0
    • Testing: qtestlib
    • None
    • ea415e20607016651f3cef02dff109235d84eb4d

      To make debugging test failures easier, each test that uses QSignalSpy should take advantage of the sanity checks performed by the QSignalSpy constructor, e.g.

      QSignalSpy spy(object, SIGNAL(someSignal()));
      QVERIFY(spy.isValid());
      

      The practice of using QSignalSpy::isValid() should also be documented in the QTestLib Manual.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            jasmcdon Jason McDonald (Closed Nokia Identity. Please assign to "macadder" instead) (Inactive)
            jasmcdon Jason McDonald (Closed Nokia Identity. Please assign to "macadder" instead) (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes