Skip to content

Commit

Permalink
Reference issue qmk#1476 from the unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fredizzimo authored and jackhumbert committed Jul 9, 2017
1 parent 67f722c commit 60b1880
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/basic/test_keypress.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ TEST_F(KeyPress, CorrectKeysAreReportedWhenTwoKeysArePressed) {
press_key(1, 0);
press_key(0, 3);
//Note that QMK only processes one key at a time
//See issue #1476 for more information
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_B)));
keyboard_task();
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_B, KC_C)));
Expand All @@ -68,6 +69,7 @@ TEST_F(KeyPress, LeftShiftIsReportedCorrectly) {
press_key(3, 0);
press_key(0, 0);
// Unfortunately modifiers are also processed in the wrong order
// See issue #1476 for more information
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_A)));
keyboard_task();
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_A, KC_LSFT)));
Expand All @@ -85,6 +87,7 @@ TEST_F(KeyPress, PressLeftShiftAndControl) {
press_key(3, 0);
press_key(5, 0);
// Unfortunately modifiers are also processed in the wrong order
// See issue #1476 for more information
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_LSFT)));
keyboard_task();
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_LSFT, KC_LCTRL)));
Expand All @@ -96,6 +99,7 @@ TEST_F(KeyPress, LeftAndRightShiftCanBePressedAtTheSameTime) {
press_key(3, 0);
press_key(4, 0);
// Unfortunately modifiers are also processed in the wrong order
// See issue #1476 for more information
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_LSFT)));
keyboard_task();
EXPECT_CALL(driver, send_keyboard_mock(KeyboardReport(KC_LSFT, KC_RSFT)));
Expand Down

0 comments on commit 60b1880

Please sign in to comment.