From 167da771f6833809074820908200d0d1e533ecae Mon Sep 17 00:00:00 2001 From: Edward Welbourne Date: Wed, 5 Oct 2022 12:32:35 +0200 Subject: [PATCH] tst_QRE::wildcard(): use more informative data row tags Using simply the pattern didn't work so well when some patters are used repeatedly, on different haystacks. So include the haystack in the tag name. Remove one straight up duplicate row. Change-Id: Ib46364581f23c493e83d75e6d04ab09e4329a3a5 Reviewed-by: Giuseppe D'Angelo Reviewed-by: Samuel Gaist --- .../corelib/text/qregularexpression/tst_qregularexpression.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/auto/corelib/text/qregularexpression/tst_qregularexpression.cpp b/tests/auto/corelib/text/qregularexpression/tst_qregularexpression.cpp index 7f3bef66e6..6d7e15de6b 100644 --- a/tests/auto/corelib/text/qregularexpression/tst_qregularexpression.cpp +++ b/tests/auto/corelib/text/qregularexpression/tst_qregularexpression.cpp @@ -2449,14 +2449,13 @@ void tst_QRegularExpression::wildcard_data() QTest::addColumn("foundIndex"); auto addRow = [](const char *pattern, const char *string, qsizetype foundIndex) { - QTest::newRow(pattern) << pattern << string << foundIndex; + QTest::addRow("%s@%s", pattern, string) << pattern << string << foundIndex; }; addRow("*.html", "test.html", 0); addRow("*.html", "test.htm", -1); addRow("*bar*", "foobarbaz", 0); addRow("*", "Qt Rocks!", 0); - addRow("*.html", "test.html", 0); addRow("*.h", "test.cpp", -1); addRow("*.???l", "test.html", 0); addRow("*?", "test.html", 0);