QmlDesigner.Tests: Use simplifiedTypeName for QtObject and Component

It is ambiguous if QtObject and Component come from QtQml or QtQuick.

Change-Id: I2e1dd48d80ee7aec8293eac85160d62a584c2819
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
Thomas Hartmann
2021-06-16 22:18:56 +02:00
parent 5369aea1ed
commit add272dbbb

View File

@@ -2894,7 +2894,7 @@ void tst_TestCore::testRewriterComponentId()
ModelNode component(rootModelNode.directSubModelNodes().first());
QVERIFY(component.isValid());
QCOMPARE(component.type(), QmlDesigner::TypeName("QtQml.Component"));
QCOMPARE(component.simplifiedTypeName(), QmlDesigner::TypeName("Component"));
QCOMPARE(component.id(), QString("testComponent"));
}
@@ -4286,7 +4286,7 @@ void tst_TestCore::testMetaInfoUncreatableType()
NodeMetaInfo qObjectTypeInfo = animationTypeInfo.directSuperClass();
QVERIFY(qObjectTypeInfo.isValid());
QCOMPARE(qObjectTypeInfo.typeName(), QmlDesigner::TypeName("QtQml.QtObject"));
QCOMPARE(qObjectTypeInfo.simplifiedTypeName(), QmlDesigner::TypeName("QtObject"));
QCOMPARE(animationTypeInfo.superClasses().size(), 2);
}