summaryrefslogtreecommitdiff
path: root/src/plugins/cpptools/cppcompletion_test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/cpptools/cppcompletion_test.cpp')
-rw-r--r--src/plugins/cpptools/cppcompletion_test.cpp22
1 files changed, 20 insertions, 2 deletions
diff --git a/src/plugins/cpptools/cppcompletion_test.cpp b/src/plugins/cpptools/cppcompletion_test.cpp
index e96c790c6c..c1e03a8401 100644
--- a/src/plugins/cpptools/cppcompletion_test.cpp
+++ b/src/plugins/cpptools/cppcompletion_test.cpp
@@ -306,8 +306,6 @@ void CppToolsPlugin::test_completion()
expectedCompletions.sort();
QEXPECT_FAIL("enum_in_function_in_struct_in_function", "doesn't work", Abort);
- QEXPECT_FAIL("nested_class_in_template_class_QTCREATORBUG-11752",
- "related to infiniteLoopLocalTypedef_QTCREATORBUG-11999", Abort);
QCOMPARE(actualCompletions, expectedCompletions);
}
@@ -2264,6 +2262,26 @@ void CppToolsPlugin::test_completion_data()
<< QLatin1String("foo")
<< QLatin1String("Foo"));
+ QTest::newRow("infiniteLoopLocalTypedef_QTCREATORBUG-11999") << _(
+ "template <typename T>\n"
+ "struct Temp\n"
+ "{\n"
+ " struct Nested\n"
+ " {\n"
+ " typedef Temp<T> TempT;\n"
+ " T t;\n"
+ " };\n"
+ " Nested nested;\n"
+ "};\n"
+ "struct Foo { int foo; };\n"
+ "void fun() {\n"
+ " Temp<Foo> tempFoo;\n"
+ " @\n"
+ "}\n"
+ ) << _("tempFoo.nested.t.") << (QStringList()
+ << QLatin1String("foo")
+ << QLatin1String("Foo"));
+
QTest::newRow("lambda_parameter") << _(
"auto func = [](int arg1) { return @; };\n"
) << _("ar") << (QStringList()