Skip to content

Commit 1893430

Browse files
committed
Added tests for multibyte
1 parent 323cdd1 commit 1893430

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

stringbuilder_test.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ func TestAppend(t *testing.T) {
1212
}{
1313
{"Hello World"},
1414
{"Hallöchen"},
15+
{"汉字汉字汉字汉字汉字汉字"},
1516
}
1617
for _, tt := range tests {
1718
t.Run(tt.want, func(t *testing.T) {
@@ -55,6 +56,7 @@ func TestLen(t *testing.T) {
5556
}{
5657
{"English word", "Hello", 5},
5758
{"Word with Umlaut", "Hallöchen", 9},
59+
{"Multibyte", "汉字", 2},
5860
}
5961
for _, tt := range tests {
6062
t.Run(tt.name, func(t *testing.T) {

0 commit comments

Comments
 (0)