aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp')
-rw-r--r--tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp25
1 files changed, 25 insertions, 0 deletions
diff --git a/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp b/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp
index fb1ab69c71..b8bb660516 100644
--- a/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp
+++ b/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp
@@ -155,6 +155,7 @@ private slots:
void listLength();
void listOfInvisible();
void listPropertyAsModel();
+ void listToString();
void lotsOfRegisters();
void math();
void mathMinMax();
@@ -2992,6 +2993,30 @@ void tst_QmlCppCodegen::listPropertyAsModel()
QCOMPARE(children.count(), 5);
}
+void tst_QmlCppCodegen::listToString()
+{
+ QQmlEngine engine;
+ QQmlComponent c(&engine, QUrl(u"qrc:/qt/qml/TestTypes/listToString.qml"_s));
+ QVERIFY2(c.isReady(), qPrintable(c.errorString()));
+
+ QTest::ignoreMessage(QtDebugMsg, "[one,two]");
+ QTest::ignoreMessage(QtDebugMsg, "one,two");
+ QTest::ignoreMessage(QtDebugMsg, "[1,2]");
+ QTest::ignoreMessage(QtDebugMsg, "1,2");
+ QTest::ignoreMessage(
+ QtDebugMsg,
+ QRegularExpression("\\[QObject_QML_[0-9]+\\(0x[0-9a-f]+\\),"
+ "QObject_QML_[0-9]+\\(0x[0-9a-f]+\\)\\]"));
+ QTest::ignoreMessage(
+ QtDebugMsg,
+ QRegularExpression("QObject_QML_[0-9]+\\(0x[0-9a-f]+\\),"
+ "QObject_QML_[0-9]+\\(0x[0-9a-f]+\\)"));
+
+ QTest::ignoreMessage(QtDebugMsg, "[a,b]");
+
+ QScopedPointer<QObject> o(c.create());
+}
+
void tst_QmlCppCodegen::lotsOfRegisters()
{
QQmlEngine engine;