MCPcopy
hub / github.com/rs/zerolog / TestDecodeBool

Function TestDecodeBool

internal/cbor/decoder_test.go:104–111  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

102}
103
104func TestDecodeBool(t *testing.T) {
105 for _, tc := range internal.BooleanTestCases {
106 got := decodeSimpleFloat(getReader(tc.Binary))
107 if string(got) != tc.Json {
108 t.Errorf("decodeSimpleFloat(0x%s)=%s, want:%s", hex.EncodeToString([]byte(tc.Binary)), string(got), tc.Json)
109 }
110 }
111}
112
113func TestDecodeFloat(t *testing.T) {
114 for _, tc := range internal.Float32TestCases {

Callers

nothing calls this directly

Calls 2

decodeSimpleFloatFunction · 0.85
getReaderFunction · 0.85

Tested by

no test coverage detected