MCPcopy Create free account
hub / github.com/apache/fory / TestAsciiEncoding

Function TestAsciiEncoding

go/fory/meta/meta_string_test.go:85–91  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

83}
84
85func TestAsciiEncoding(t *testing.T) {
86 encoder := NewEncoder('.', '_')
87
88 data, err := encoder.Encode("asciiOnly")
89 require.NoError(t, err)
90 require.NotEqual(t, UTF_8, data.GetEncoding(), "Encoding should not be UTF-8 for ASCII strings")
91}
92
93func TestNonAsciiEncoding(t *testing.T) {
94 encoder := NewEncoder('.', '_')

Callers

nothing calls this directly

Calls 3

EncodeMethod · 0.95
NewEncoderFunction · 0.85
GetEncodingMethod · 0.80

Tested by

no test coverage detected