diff options
author | BogDan Vatra <bogdan@kdab.com> | 2016-09-28 19:27:11 +0300 |
---|---|---|
committer | BogDan Vatra <bogdan@kdab.com> | 2016-09-28 16:44:19 +0000 |
commit | 87583738f960e83918da3b66e455e75c144fbf8e (patch) | |
tree | fb009e76e859d76837d3f7fd8a0b1549be553ea1 /tests/auto/tools/moc/tst_moc.cpp | |
parent | 5dbcced3bff9dffd102d07e913bdfccc6f1d2213 (diff) |
moc: support nested q_namespaces
Nested namespaces are quite common, therefore moc should support them.
Task-number: QTBUG-55415
Change-Id: I756cab36d498eb4342b402d255836d5d30f07b30
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Diffstat (limited to 'tests/auto/tools/moc/tst_moc.cpp')
-rw-r--r-- | tests/auto/tools/moc/tst_moc.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/auto/tools/moc/tst_moc.cpp b/tests/auto/tools/moc/tst_moc.cpp index 601b1bb36b..ecf6c7e992 100644 --- a/tests/auto/tools/moc/tst_moc.cpp +++ b/tests/auto/tools/moc/tst_moc.cpp @@ -3777,6 +3777,10 @@ void tst_Moc::testQNamespace() QCOMPARE(meta.name(), "TestEnum1"); QCOMPARE(meta.enclosingMetaObject(), &TestQNamespace::staticMetaObject); QCOMPARE(meta.keyCount(), 2); + + QCOMPARE(FooNamespace::staticMetaObject.enumeratorCount(), 1); + QCOMPARE(FooNamespace::FooNestedNamespace::staticMetaObject.enumeratorCount(), 2); + QCOMPARE(FooNamespace::FooNestedNamespace::FooMoreNestedNamespace::staticMetaObject.enumeratorCount(), 1); } QTEST_MAIN(tst_Moc) |