MCPcopy Create free account
hub / github.com/brimdata/super / TestTypeValue

Function TestTypeValue

sup/typeval_test.go:11–18  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

9)
10
11func TestTypeValue(t *testing.T) {
12 const s = "{A:{B:int64},C:int32}"
13 sctx := super.NewContext()
14 typ, err := sup.ParseType(sctx, s)
15 require.NoError(t, err)
16 tv := sctx.LookupTypeValue(typ)
17 require.Exactly(t, s, sup.FormatTypeValue(tv.Bytes()))
18}
19
20func TestTypeValueCrossContext(t *testing.T) {
21 const s = "{A:{B:int64},C:int32}"

Callers

nothing calls this directly

Calls 5

LookupTypeValueMethod · 0.95
NewContextFunction · 0.92
ParseTypeFunction · 0.92
FormatTypeValueFunction · 0.92
BytesMethod · 0.45

Tested by

no test coverage detected