D16326: Replace leading typed text when completing function implementation
Amish Naidu
noreply at phabricator.kde.org
Sat Oct 20 09:42:41 BST 2018
amhndu updated this revision to Diff 43961.
amhndu added a comment.
Added tests in testCompleteFunction, which already has some implements-completion
tests. Should I move them to a different test, something like testImplementExecute
in a different patch or this one ?
Completion tests are also broken, crashing after executing a single test case
because of a delayed connection, triggering the slot only after the document is closed.
As a workaround, I've used
diff --git a/plugins/clang/tests/codecompletiontestbase.cpp b/plugins/clang/tests/codecompletiontestbase.cpp
index 5b351d0d27..282f7da36e 100644
--- a/plugins/clang/tests/codecompletiontestbase.cpp
+++ b/plugins/clang/tests/codecompletiontestbase.cpp
@@ -70,6 +70,7 @@ void CodeCompletionTestBase::initTestCase()
m_projectController = new TestProjectController(core);
core->setProjectController(m_projectController);
ICore::self()->documentController()->closeAllDocuments();
+ QObject::disconnect(ICore::self()->documentController(), nullptr, nullptr, nullptr);
ClangSettingsManager::self()->m_enableTesting = true;
}
Which still has a crash, but only at the very end after executing everything.
REPOSITORY
R32 KDevelop
CHANGES SINCE LAST UPDATE
https://phabricator.kde.org/D16326?vs=43945&id=43961
BRANCH
implements-replace
REVISION DETAIL
https://phabricator.kde.org/D16326
AFFECTED FILES
plugins/clang/codecompletion/context.cpp
plugins/clang/tests/test_codecompletion.cpp
To: amhndu, #kdevelop
Cc: apol, kdevelop-devel, glebaccon, antismap, iodelay, vbspam, geetamc, Pilzschaf, akshaydeo, surgenight, arrowd
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20181020/9da5f53a/attachment.html>
More information about the KDevelop-devel
mailing list