summaryrefslogtreecommitdiff
path: root/core/fxcrt/widestring_unittest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fxcrt/widestring_unittest.cpp')
-rw-r--r--core/fxcrt/widestring_unittest.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/core/fxcrt/widestring_unittest.cpp b/core/fxcrt/widestring_unittest.cpp
index ec0a55fc1e..4572305530 100644
--- a/core/fxcrt/widestring_unittest.cpp
+++ b/core/fxcrt/widestring_unittest.cpp
@@ -1353,8 +1353,14 @@ TEST(WideString, Empty) {
WideString empty_str;
EXPECT_TRUE(empty_str.IsEmpty());
EXPECT_EQ(0u, empty_str.GetLength());
+
const wchar_t* cstr = empty_str.c_str();
+ EXPECT_NE(nullptr, cstr);
EXPECT_EQ(0u, wcslen(cstr));
+
+ pdfium::span<const wchar_t> cspan = empty_str.AsSpan();
+ EXPECT_TRUE(cspan.empty());
+ EXPECT_EQ(nullptr, cspan.data());
}
TEST(CFX_WidString, InitializerList) {