AutoTest: Fix marking for removal and sweeping of Quick Tests

If opening and editing a QML file we did no more mark tests of this
file as to be removed. In turn we may have got "new" items when e.g.
just modifying the name of a function or test case and but did not lose
the old one.
Broke with 90fd6870c5.

Change-Id: I86917089ffb9d4acb2f735f2f3e0f112d8cdc65a
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
Christian Stenger
2020-09-24 09:34:22 +02:00
parent ee601e548e
commit af9d8768dc

View File

@@ -428,6 +428,7 @@ QSet<QString> QuickTestTreeItem::internalTargets() const
void QuickTestTreeItem::markForRemovalRecursively(const QString &filePath)
{
TestTreeItem::markForRemovalRecursively(filePath);
auto parser = dynamic_cast<QuickTestParser *>(framework()->testParser());
const QString proFile = parser->projectFileForMainCppFile(filePath);
if (!proFile.isEmpty()) {