summaryrefslogtreecommitdiffstats
path: root/tests/auto/qkeysequence
diff options
context:
space:
mode:
authorRohan McGovern <rohan.mcgovern@nokia.com>2010-02-01 06:02:59 (GMT)
committerRohan McGovern <rohan.mcgovern@nokia.com>2010-02-01 06:02:59 (GMT)
commitdc1cab966938edc5463f26189607ece134549a22 (patch)
treeecaab6c64758f41fa9cb5b376b395831a77e6c83 /tests/auto/qkeysequence
parent4915439de467d1119a46af66ea08dbe161d2f336 (diff)
parentbde40a9fa852107c237ac408f93a33b5955b9290 (diff)
downloadQt-dc1cab966938edc5463f26189607ece134549a22.zip
Qt-dc1cab966938edc5463f26189607ece134549a22.tar.gz
Qt-dc1cab966938edc5463f26189607ece134549a22.tar.bz2
Merge commit 'oslo1/master' into oslo1-master
Conflicts: doc/src/getting-started/installation.qdoc src/gui/dialogs/qfiledialog_win.cpp tools/assistant/tools/assistant/centralwidget.cpp tools/assistant/tools/assistant/helpviewer.cpp
Diffstat (limited to 'tests/auto/qkeysequence')
-rw-r--r--tests/auto/qkeysequence/tst_qkeysequence.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/auto/qkeysequence/tst_qkeysequence.cpp b/tests/auto/qkeysequence/tst_qkeysequence.cpp
index 3e3f202..b1ef223 100644
--- a/tests/auto/qkeysequence/tst_qkeysequence.cpp
+++ b/tests/auto/qkeysequence/tst_qkeysequence.cpp
@@ -119,6 +119,7 @@ private slots:
void symetricConstructors_data();
void symetricConstructors();
void checkMultipleNames();
+ void checkMultipleCodes();
void mnemonic_data();
void mnemonic();
void toString_data();
@@ -265,6 +266,18 @@ void tst_QKeySequence::checkMultipleNames()
QVERIFY( oldK == newK );
}
+//TODO: could test third constructor, or test fromString on all constructor-data
+void tst_QKeySequence::checkMultipleCodes()
+{
+ QKeySequence seq1("Alt+d, l");
+ QKeySequence seq2 = QKeySequence::fromString("Alt+d, l");
+ QVERIFY( seq1 == seq2 );
+
+ QKeySequence seq3("Alt+d,l");
+ QKeySequence seq4 = QKeySequence::fromString("Alt+d,l");
+ QVERIFY( seq3 == seq4 );
+}
+
/*
* We must ensure that the keyBindings data is allways sorted
* so that we can safely perform binary searches.