diff options
author | Stefan Kerkmann <karlk90@pm.me> | 2022-08-06 12:51:13 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-06 20:51:13 +1000 |
commit | f27b617f36d55ac5469247016a1b79304f892366 (patch) | |
tree | 3334b3b4cf653fa131eef0729529c06450e12168 /tests | |
parent | e9f9f99a3374ad46e9a2baf2fe35c3f1d0715d4b (diff) |
[Core] Process all changed keys in one scan loop, deprecate `QMK_KEYS_PER_SCAN` (#15292)
Diffstat (limited to 'tests')
-rw-r--r-- | tests/basic/test_keypress.cpp | 22 | ||||
-rw-r--r-- | tests/tap_dance/test_examples.cpp | 3 |
2 files changed, 1 insertions, 24 deletions
diff --git a/tests/basic/test_keypress.cpp b/tests/basic/test_keypress.cpp index bb68ced557..6d5b502a00 100644 --- a/tests/basic/test_keypress.cpp +++ b/tests/basic/test_keypress.cpp @@ -64,11 +64,7 @@ TEST_F(KeyPress, CorrectKeysAreReportedWhenTwoKeysArePressed) { key_b.press(); key_c.press(); - // Note that QMK only processes one key at a time - // See issue #1476 for more information EXPECT_REPORT(driver, (key_b.report_code)); - keyboard_task(); - EXPECT_REPORT(driver, (key_b.report_code, key_c.report_code)); keyboard_task(); @@ -76,8 +72,6 @@ TEST_F(KeyPress, CorrectKeysAreReportedWhenTwoKeysArePressed) { key_c.release(); // Note that the first key released is the first one in the matrix order EXPECT_REPORT(driver, (key_c.report_code)); - keyboard_task(); - EXPECT_EMPTY_REPORT(driver); keyboard_task(); } @@ -92,10 +86,7 @@ TEST_F(KeyPress, LeftShiftIsReportedCorrectly) { key_lsft.press(); key_a.press(); - // Unfortunately modifiers are also processed in the wrong order - // See issue #1476 for more information EXPECT_REPORT(driver, (key_a.report_code)); - keyboard_task(); EXPECT_REPORT(driver, (key_a.report_code, key_lsft.report_code)); keyboard_task(); @@ -118,11 +109,7 @@ TEST_F(KeyPress, PressLeftShiftAndControl) { key_lsft.press(); key_lctrl.press(); - // Unfortunately modifiers are also processed in the wrong order - // See issue #1476 for more information EXPECT_REPORT(driver, (key_lsft.report_code)); - keyboard_task(); - EXPECT_REPORT(driver, (key_lsft.report_code, key_lctrl.report_code)); keyboard_task(); @@ -130,8 +117,6 @@ TEST_F(KeyPress, PressLeftShiftAndControl) { key_lctrl.release(); EXPECT_REPORT(driver, (key_lctrl.report_code)); - keyboard_task(); - EXPECT_EMPTY_REPORT(driver); keyboard_task(); } @@ -145,20 +130,13 @@ TEST_F(KeyPress, LeftAndRightShiftCanBePressedAtTheSameTime) { key_lsft.press(); key_rsft.press(); - // Unfortunately modifiers are also processed in the wrong order - // See issue #1476 for more information EXPECT_REPORT(driver, (key_lsft.report_code)); - keyboard_task(); - EXPECT_REPORT(driver, (key_lsft.report_code, key_rsft.report_code)); keyboard_task(); key_lsft.release(); key_rsft.release(); - EXPECT_REPORT(driver, (key_rsft.report_code)); - keyboard_task(); - EXPECT_EMPTY_REPORT(driver); keyboard_task(); } diff --git a/tests/tap_dance/test_examples.cpp b/tests/tap_dance/test_examples.cpp index e67e6cb907..6dabc45513 100644 --- a/tests/tap_dance/test_examples.cpp +++ b/tests/tap_dance/test_examples.cpp @@ -92,10 +92,9 @@ TEST_F(TapDance, DoubleTapWithMod) { key_shift.release(); key_esc_caps.press(); EXPECT_REPORT(driver, (KC_LSFT, KC_CAPS)); + EXPECT_REPORT(driver, (KC_CAPS)); run_one_scan_loop(); key_esc_caps.release(); - EXPECT_REPORT(driver, (KC_LSFT)); - run_one_scan_loop(); EXPECT_EMPTY_REPORT(driver); run_one_scan_loop(); } |