upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/tests/unit
diff options
context:
space:
mode:
authorYour Name <you@example.com>2026-05-18 23:41:19 +0530
committerYour Name <you@example.com>2026-05-18 23:41:19 +0530
commit699fc6c03899c3b1ff853d8c7c6cf32173436354 (patch)
treea1dbf26b3d2c6ea3dc12a5c8ee443c00b364bb4d /tests/unit
parent9ff7cffcff11237288cfddecee2684f499d23ddf (diff)
fix: keyboard KB_START_Y must match render position (70), simplify row 3 layout
- KB_START_Y was 310 but keyboard rendered at y=70 — touch hits never matched - Row 3 simplified to 3 keys: [layer/shift, space, done] - All 362 unit tests pass
Diffstat (limited to 'tests/unit')
-rw-r--r--tests/unit/test_keyboard.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/unit/test_keyboard.c b/tests/unit/test_keyboard.c
index 4cb923d..e069f28 100644
--- a/tests/unit/test_keyboard.c
+++ b/tests/unit/test_keyboard.c
@@ -38,10 +38,10 @@ int main(void)
38 ASSERT_EQ_INT(0, count, "Invalid row 99 returns 0"); 38 ASSERT_EQ_INT(0, count, "Invalid row 99 returns 0");
39 39
40 { 40 {
41 kb_result_t r = kb_hit_test(160, 100, KB_ALPHA_LOWER); 41 kb_result_t r = kb_hit_test(160, 10, KB_ALPHA_LOWER);
42 ASSERT(r.action == KB_ACTION_NONE, "Touch above keyboard = NONE"); 42 ASSERT(r.action == KB_ACTION_NONE, "Touch above keyboard = NONE");
43 43
44 r = kb_hit_test(160, 500, KB_ALPHA_LOWER); 44 r = kb_hit_test(160, KB_START_Y + KB_ROW_COUNT * (KB_KEY_H + KB_KEY_GAP) + 10, KB_ALPHA_LOWER);
45 ASSERT(r.action == KB_ACTION_NONE, "Touch below keyboard = NONE"); 45 ASSERT(r.action == KB_ACTION_NONE, "Touch below keyboard = NONE");
46 } 46 }
47 47