From 70e34e491c297231a3f987fd69760d38e79dbfa4 Mon Sep 17 00:00:00 2001 From: Ryan Date: Sun, 27 Aug 2023 13:30:19 +1000 Subject: Unicode, Unicodemap and UCIS refactor (#21659) --- tests/unicode/unicode_basic/test_unicode_basic.cpp | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 tests/unicode/unicode_basic/test_unicode_basic.cpp (limited to 'tests/unicode/unicode_basic/test_unicode_basic.cpp') diff --git a/tests/unicode/unicode_basic/test_unicode_basic.cpp b/tests/unicode/unicode_basic/test_unicode_basic.cpp new file mode 100644 index 0000000000..598b57277f --- /dev/null +++ b/tests/unicode/unicode_basic/test_unicode_basic.cpp @@ -0,0 +1,26 @@ +// Copyright 2023 QMK +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "keyboard_report_util.hpp" +#include "keycode.h" +#include "test_common.hpp" +#include "test_keymap_key.hpp" + +using testing::_; + +class UnicodeBasic : public TestFixture {}; + +TEST_F(UnicodeBasic, sends_unicode_sequence) { + TestDriver driver; + + set_unicode_input_mode(UNICODE_MODE_LINUX); + + auto key_uc = KeymapKey(0, 0, 0, UC(0x03A8)); // Ψ + + set_keymap({key_uc}); + + EXPECT_UNICODE(driver, 0x03A8); + tap_key(key_uc); + + VERIFY_AND_CLEAR(driver); +} -- cgit v1.2.3