From 6f6600a50185558c2bd3a37fdb5348e4a001322e Mon Sep 17 00:00:00 2001 From: Ross Date: Mon, 15 Nov 2021 12:16:10 +1000 Subject: [PATCH] feat(windows): Rename kbd file fix meson build for key list test --- .../desktop/tests/unit/kmx/kmx_key_list.cpp | 7 +++---- ... - groups ctrlalt.kmn => kmx_key_list.kmn} | 2 +- .../desktop/tests/unit/kmx/kmx_key_list.kmx | Bin 0 -> 806 bytes .../core/desktop/tests/unit/kmx/meson.build | 18 ++++++++++++++++-- 4 files changed, 20 insertions(+), 7 deletions(-) rename common/core/desktop/tests/unit/kmx/{049 - groups ctrlalt.kmn => kmx_key_list.kmn} (74%) create mode 100644 common/core/desktop/tests/unit/kmx/kmx_key_list.kmx diff --git a/common/core/desktop/tests/unit/kmx/kmx_key_list.cpp b/common/core/desktop/tests/unit/kmx/kmx_key_list.cpp index f9e39d86d5..2b518c8603 100644 --- a/common/core/desktop/tests/unit/kmx/kmx_key_list.cpp +++ b/common/core/desktop/tests/unit/kmx/kmx_key_list.cpp @@ -32,16 +32,15 @@ km_kbp_keyboard_key kb_key_expected_list[] = {{49,16384},{50,16384},{66,16416},{ * The purpose of this test is to verify that `km_kbp_keyboard_get_key_list` * returns list of all the keys used for a keyboard that core as loaded. * - * @param source_path Path to kmx keyboard file + * @param source_file Path to kmx keyboard file */ -void test_key_list(const km::kbp::path &source_path){ +void test_key_list(const km::kbp::path &source_file){ km_kbp_keyboard * test_kb = nullptr; km_kbp_state * test_state = nullptr; km_kbp_keyboard_key * kb_key_list; - km::kbp::path const source_keybard = "049 - groups ctrlalt.kmx"; - km::kbp::path full_path = km::kbp::path::join(source_path, source_keybard); + km::kbp::path full_path = source_file; try_status(km_kbp_keyboard_load(full_path.native().c_str(), &test_kb)); diff --git a/common/core/desktop/tests/unit/kmx/049 - groups ctrlalt.kmn b/common/core/desktop/tests/unit/kmx/kmx_key_list.kmn similarity index 74% rename from common/core/desktop/tests/unit/kmx/049 - groups ctrlalt.kmn rename to common/core/desktop/tests/unit/kmx/kmx_key_list.kmn index 8980d06f2b..cd55d2a40d 100644 --- a/common/core/desktop/tests/unit/kmx/049 - groups ctrlalt.kmn +++ b/common/core/desktop/tests/unit/kmx/kmx_key_list.kmn @@ -1,4 +1,4 @@ -c Description: Tests multiple groups. Purpose here is to interleave output and backspaces from kmx processor to consumer +c Description: Tests multiple groups. This keyboard is used to test km_kbp_keyboard_get_key_list API call c keys: [K_1][K_2] c expected: abc c context: diff --git a/common/core/desktop/tests/unit/kmx/kmx_key_list.kmx b/common/core/desktop/tests/unit/kmx/kmx_key_list.kmx new file mode 100644 index 0000000000000000000000000000000000000000..68d44f583def8648bdefff9d279412e3ba5df2fc GIT binary patch literal 806 zcmZvaxk>|J6opTWf{05BH=@WOl2VeWsE}evgcKn*MzGBy7*QiJ#-+AMVPRn*V&NlL z`UGNYXCW4nLM(iR_}$4ULH*&Id(OH4#>`|ka%<|7o)XPNF#`5r5Ge>QJQB7T$e$6h zCSwG`^zW&o;GidA3>~FTLoYf(jY9~XqptdTn_BYqDYfS72KCI>x72GGX6*y@4pORW zQ+d^RmgMM2W%L#*Lvo^BdV9DPTpe~)(LS|GX1=NeR#dz>F)e6TQHW_?bDriX5*wZS znU8rhtrz*VQ@bannc*nQ4a)3q=`znW)gj|OaEkdjzJOYSq}G{RR*^fExSy?BoyRHapiICj9#j`3%Z z#1DewN)7xur0_%Fl3n00A&<9ng5FtnpMsBdieU8{`@d{Fv+@O!XzxFBrC0nL*eUkE oiL8l#2ivE;bEhtlg}n~DaP$<|>IraN?v9^