Commit d1858491 authored by Nikolai Kosjar's avatar Nikolai Kosjar

CppTools: Tests: Introduce basic BuiltinSymbolSearcher tests

Change-Id: I25f11e80747863f797d146980d8ee0e605acb6e5
Reviewed-by: default avatarErik Verbruggen <erik.verbruggen@digia.com>
parent 3256b7b2
......@@ -103,7 +103,8 @@ equals(TEST, 1) {
cppmodelmanager_test.cpp \
modelmanagertesthelper.cpp \
cpppointerdeclarationformatter_test.cpp \
cpplocatorfilter_test.cpp
cpplocatorfilter_test.cpp \
symbolsearcher_test.cpp
HEADERS += \
cpppreprocessertesthelper.h \
......
......@@ -120,7 +120,8 @@ QtcPlugin {
"cppmodelmanager_test.cpp",
"modelmanagertesthelper.cpp", "modelmanagertesthelper.h",
"cpppointerdeclarationformatter_test.cpp",
"cpplocatorfilter_test.cpp"
"cpplocatorfilter_test.cpp",
"symbolsearcher_test.cpp"
]
cpp.defines: outer.concat(['SRCDIR="' + FileInfo.path(filePath) + '"'])
......
......@@ -204,6 +204,9 @@ private slots:
void test_cpplocatorfilters_CppLocatorFilter_data();
void test_cpplocatorfilters_CppCurrentDocumentFilter();
void test_builtinsymbolsearcher();
void test_builtinsymbolsearcher_data();
private:
void test_completion();
#endif
......
This diff is collapsed.
// Copyright header
//
// Symbols in a global namespace
//
int myVariable;
int myFunction(bool yesno, int number) {}
enum MyEnum { V1, V2 };
class MyClass
{
public:
MyClass() {}
int function1();
int function2(bool yesno, int number) {}
};
//
// Symbols in a named namespace
//
namespace MyNamespace {
int myVariable;
int myFunction(bool yesno, int number) {}
enum MyEnum { V1, V2 };
class MyClass
{
public:
MyClass() {}
int function1();
int function2(bool yesno, int number) {}
};
} // namespace MyNamespace
//
// Symbols in an anonymous namespace
//
namespace {
int myVariable;
int myFunction(bool yesno, int number) {}
enum MyEnum { V1, V2 };
class MyClass
{
public:
MyClass() {}
int function1();
int function2(bool yesno, int number) {}
};
} // anonymous namespace
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment