aboutsummaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2025-02-04 09:49:10 +1100
committerNeil <nyamatongwe@gmail.com>2025-02-04 09:49:10 +1100
commitef961772c3ced424f034c2055263d7231eccee01 (patch)
treedd6d87ad09d3c474ccc93c57598e20e302ed1599 /test
parentf54fd2019dd648b29a80ec7429833ab546d3a428 (diff)
downloadscintilla-mirror-ef961772c3ced424f034c2055263d7231eccee01.tar.gz
Add overload of UnicodeFromUTF8 that takes a string_view.
Diffstat (limited to 'test')
-rw-r--r--test/unit/testUniConversion.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/unit/testUniConversion.cxx b/test/unit/testUniConversion.cxx
index 0327db7e1..a3b15d84c 100644
--- a/test/unit/testUniConversion.cxx
+++ b/test/unit/testUniConversion.cxx
@@ -108,6 +108,11 @@ TEST_CASE("UniConversion") {
REQUIRE(UnicodeFromUTF8(s) == 0x10348);
}
+ SECTION("UnicodeFromUTF8 StringView") {
+ const unsigned char s[]="\xF0\x90\x8D\x88";
+ REQUIRE(UnicodeFromUTF8(s) == 0x10348);
+ }
+
// UTF16FromUTF8
SECTION("UTF16FromUTF8 ASCII") {