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

QTest::newRow() cannot read INT_MIN (int32), value -2147483648

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P3: Somewhat important
    • None
    • 5.9.9
    • Testing: qtestlib
    • None
    • Kit: Desktop Qt 5.9.9 MinGW 32bit
      Config: Using QtTest library 5.9.9, Qt 5.9.9 (i386-little_endian-ilp32 shared (dynamic) debug build; by GCC 5.3.0)
    • Windows

    Description

       

      // — Code —

      void TestCalculator::testDiff_data() {

      QTest::addColumn<int>("a");

      QTest::addColumn<int>("b");

      QTest::addColumn<int>("result");

      QTest::newRow("INT_MIN - 0") << -2147483648 << 0 << -2147483648;

      // -> error message: QDEBUG : TestCalculator::testDiff() expected data of type 'int', got 'qlonglong' for element 0 of data with tag 'INT_MIN - 0' {color}}

       

       

      Attachments

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

        Activity

          People

            macadder Jason McDonald
            martintester M. Pe.
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes