QmlDesigner: Fix designer's unit tests

Change-Id: I8da4b6d62beef6e4101fbc331d9877ac7bb0398c
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
Vikas Pachdha
2021-02-24 14:28:33 +01:00
parent 6608bf1ad5
commit fbf509dd0b

View File

@@ -337,7 +337,9 @@ void SubComponentManager::registerQmlFile(const QFileInfo &fileInfo, const QStri
ItemLibraryEntry itemLibraryEntry; ItemLibraryEntry itemLibraryEntry;
itemLibraryEntry.setType(componentName.toUtf8()); itemLibraryEntry.setType(componentName.toUtf8());
itemLibraryEntry.setName(baseComponentName); itemLibraryEntry.setName(baseComponentName);
#ifndef QMLDESIGNER_TEST
itemLibraryEntry.setCategory(ItemLibraryImport::userComponentsTitle()); itemLibraryEntry.setCategory(ItemLibraryImport::userComponentsTitle());
#endif
itemLibraryEntry.setCustomComponentSource(fileInfo.absoluteFilePath()); itemLibraryEntry.setCustomComponentSource(fileInfo.absoluteFilePath());
if (!qualifier.isEmpty()) { if (!qualifier.isEmpty()) {
itemLibraryEntry.setRequiredImport(fixedQualifier); itemLibraryEntry.setRequiredImport(fixedQualifier);