aboutsummaryrefslogtreecommitdiffstats
path: root/tests/testnestedtypes.cpp
diff options
context:
space:
mode:
authorMarcelo Lira <marcelo.lira@openbossa.org>2011-12-23 15:10:17 -0300
committerHugo Parente Lima <hugo.pl@gmail.com>2012-03-09 19:10:21 -0300
commit4889efc199243af54cf71accffb3f9554cba933d (patch)
treec08e9b0b65074868454f09807c51455a582a5410 /tests/testnestedtypes.cpp
parentab94961a639cc7b364fcb1e3f68531792c312990 (diff)
Added the "<custom-type>" tag, and better requirements for function signatures.sb-0.10.10
Trying to find a non-qualified (without scope information) class, found in a function signature or return type, was a bad idea for it makes the parsing awfully slow when dealing with huge libraries. If the user writes a type in short form in a function signature (e.g. "SomeClass", instead of "Namespace::SomeClass"), APIExtractor will exit with a message indicating the error and the possible candidates for the type. The "<custom-type>" tag is for types of the target language ("PyObject" in Python, for instance) and will be handled by the generator. Reviewed by Hugo Parente <hugo.lima@openbossa.org> Reviewed by Paulo Alcantara <pcacjr@gmail.com>
Diffstat (limited to 'tests/testnestedtypes.cpp')
-rw-r--r--tests/testnestedtypes.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/testnestedtypes.cpp b/tests/testnestedtypes.cpp
index 4e000cb08..83512f7db 100644
--- a/tests/testnestedtypes.cpp
+++ b/tests/testnestedtypes.cpp
@@ -93,7 +93,7 @@ void TestNestedTypes::testDuplicationOfNestedTypes()
<typesystem package='Foo'> \
<namespace-type name='Namespace'>\
<value-type name='SomeClass'>\
- <add-function signature='createSomeClass(SomeClass)'/>\
+ <add-function signature='createSomeClass(Namespace::SomeClass)'/>\
</value-type>\
</namespace-type>\
</typesystem>";
@@ -114,7 +114,7 @@ void TestNestedTypes::testDuplicationOfNestedTypes()
TypeEntry* t1 = TypeDatabase::instance()->findType("Namespace::SomeClass");
QVERIFY(t1);
TypeEntry* t2 = TypeDatabase::instance()->findType("SomeClass");
- QCOMPARE(t1, t2);
+ QVERIFY(!t2);
}
QTEST_APPLESS_MAIN(TestNestedTypes)