summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorhjk <qtc-committer@nokia.com>2009-01-07 15:31:58 +0100
committerhjk <qtc-committer@nokia.com>2009-01-07 15:31:58 +0100
commit16b2c83dc8229987834a37d2cd5f4a7fb2d85767 (patch)
tree36d401c7b6246d3f2dc2e8beb80789b81e39c679 /tests
parentde376227485205332cc8de2955192fd7602d86af (diff)
downloadqt-creator-16b2c83dc8229987834a37d2cd5f4a7fb2d85767.tar.gz
add a test case for multimaps
Diffstat (limited to 'tests')
-rw-r--r--tests/manual/gdbdebugger/simple/app.cpp27
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/manual/gdbdebugger/simple/app.cpp b/tests/manual/gdbdebugger/simple/app.cpp
index 3243e9c70e..94b7e7c7e9 100644
--- a/tests/manual/gdbdebugger/simple/app.cpp
+++ b/tests/manual/gdbdebugger/simple/app.cpp
@@ -289,6 +289,32 @@ void testQMap()
#endif
}
+void testQMultiMap()
+{
+ QMultiMap<uint, float> gg0;
+ gg0.insert(11, 11.0);
+ gg0.insert(22, 22.0);
+ gg0.insert(22, 33.0);
+
+ QMultiMap<QString, float> gg1;
+ gg1.insert("22.0", 22.0);
+
+ QMultiMap<int, QString> gg2;
+ gg2.insert(22, "22.0");
+
+ QMultiMap<QString, Foo> gg3;
+ gg3.insert("22.0", Foo(22));
+ gg3.insert("33.0", Foo(33));
+ gg3.insert("22.0", Foo(22));
+
+ QObject ob;
+ QMultiMap<QString, QPointer<QObject> > map;
+ map.insert("Hallo", QPointer<QObject>(&ob));
+ map.insert("Welt", QPointer<QObject>(&ob));
+ map.insert(".", QPointer<QObject>(&ob));
+ map.insert(".", QPointer<QObject>(&ob));
+}
+
void testQObject(int &argc, char *argv[])
{
QApplication app(argc, argv);
@@ -856,6 +882,7 @@ int main(int argc, char *argv[])
testQHash();
testQImage();
testQMap();
+ testQMultiMap();
testQString();
testQSet();
testQStringList();