CppEditor: Fix testing

Now that clangd is enabled by default, we must explicitly turn it off to
test the built-in follow symbol functionality.

Change-Id: Ib275893a920145868b314ce02e9dd80f656bade4
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
Christian Kandeler
2022-01-31 16:00:39 +01:00
parent e24b91555b
commit 41fee90d8e

View File

@@ -251,7 +251,7 @@ F2TestCase::F2TestCase(CppEditorAction action,
const QString curTestName = QLatin1String(QTest::currentTestFunction());
const QString tag = QLatin1String(QTest::currentDataTag());
const bool useClangd = ClangdSettings::instance().useClangd();
const bool useClangd = m_testKit;
if (useClangd) {
if (curTestName == "testFollowSymbolQObjectConnect"
|| curTestName == "testFollowSymbolQObjectOldStyleConnect") {
@@ -442,7 +442,7 @@ F2TestCase::F2TestCase(CppEditorAction action,
// qDebug() << "Expected line:" << expectedLine;
// qDebug() << "Expected column:" << expectedColumn;
if (!ClangdSettings::instance().useClangd()) {
if (!useClangd) {
QEXPECT_FAIL("globalVarFromEnum", "Contributor works on a fix.", Abort);
QEXPECT_FAIL("matchFunctionSignature_Follow_5", "foo(int) resolved as CallAST", Abort);
}