Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-29146

For tests with multiple failures, only the latest failure is reported (somewhat) correctly in the test result view (googletest)

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2: Important
    • None
    • Qt Creator 10.0.1
    • Test Integration
    • None
    • Windows
    • 979f938aa (10.0)

    Description

      I wrote a simple example to demonstrate the issue:

       

      #include <gtest/gtest.h>
      
      TEST(testWithMultipleFailures, tests) {
        EXPECT_TRUE(false);
        EXPECT_EQ(1, 2);
        EXPECT_NE(2, 2);
      }
      
      int main(int argc, char *argv[]) { 
       ::testing::InitGoogleTest();
        return RUN_ALL_TESTS();
      } 

      This is how the output in the test result pane looks like in 9.0.2:

      The three failure entries are clickable and unfold the googletest assertion information about the actual failure. All three failures are grouped below the test name which is collapsable. Additionally, each failure is listed with the respective line where it happened.

      This is is the output in 10.0.1:

      You will notice the differences here:

      • All failures have the same text
      • The first and second failure are not clickable and reveal no information about the actual failure
      • The third failure is expendable and reveals the actual failure
      • Once that is clicked, it will reveal the context information (not shown in the screenshot)
      • All line numbers in the output are set to the line number where the first failure occurred, except the third failure, which has the correct line number

      That looks like something has been accidentially changed in the output parser.

       

      I cannot say whether the issue was present in 10.0.0 as well.

      Attachments

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

        Activity

          People

            cstenger Christian Stenger
            darkmattercoder Jochen Bauer
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes