summaryrefslogtreecommitdiff
path: root/tests/basic/keypress.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/basic/keypress.cpp')
-rw-r--r--tests/basic/keypress.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/basic/keypress.cpp b/tests/basic/keypress.cpp
index f574481f24..2b8b96b228 100644
--- a/tests/basic/keypress.cpp
+++ b/tests/basic/keypress.cpp
@@ -44,10 +44,19 @@ TEST_F(KeyPress, CorrectKeyIsReportedWhenPressed) {
TEST_F(KeyPress, CorrectKeysAreReportedWhenTwoKeysArePressed) {
TestDriver driver;
press_key(1, 0);
- press_key(0, 1);
+ press_key(0, 3);
//Note that QMK only processes one key at a time
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_B)));
keyboard_task();
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_B, KC_C)));
keyboard_task();
}
+
+TEST_F(KeyPress, ANonMappedKeyDoesNothing) {
+ TestDriver driver;
+ press_key(2, 0);
+ //Note that QMK only processes one key at a time
+ EXPECT_CALL(driver, send_keyboard_mock(_)).Times(0);
+ keyboard_task();
+ keyboard_task();
+} \ No newline at end of file