aboutsummaryrefslogtreecommitdiff
path: root/autotests/kstandardshortcuttest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'autotests/kstandardshortcuttest.cpp')
-rw-r--r--autotests/kstandardshortcuttest.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/autotests/kstandardshortcuttest.cpp b/autotests/kstandardshortcuttest.cpp
index 53a724f9..8c4df027 100644
--- a/autotests/kstandardshortcuttest.cpp
+++ b/autotests/kstandardshortcuttest.cpp
@@ -44,3 +44,10 @@ void KStandardShortcutTest::testFindStdAccel()
QCOMPARE(KStandardShortcut::find(QString("Ctrl+Shift+Alt+G")), KStandardShortcut::AccelNone);
}
+void KStandardShortcutTest::testFindByName()
+{
+ for (int i = KStandardShortcut::AccelNone + 1; i < KStandardShortcut::StandardShortcutCount; ++i) {
+ const auto id = static_cast<KStandardShortcut::StandardShortcut>(i);
+ QCOMPARE(id, KStandardShortcut::findByName(KStandardShortcut::name(id)));
+ }
+}