MCPcopy Create free account
hub / github.com/cel-expr/cel-go / TestReferenceInfoToProtoError

Function TestReferenceInfoToProtoError

common/ast/conversion_test.go:676–682  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

674}
675
676func TestReferenceInfoToProtoError(t *testing.T) {
677 out, err := ast.ReferenceInfoToProto(
678 ast.NewIdentReference("SECOND", types.Duration{Duration: time.Duration(1) * time.Second}))
679 if err == nil {
680 t.Errorf("ReferenceInfoToProto() got %v, wanted error", out)
681 }
682}
683
684func TestProtoToReferenceInfoError(t *testing.T) {
685 out, err := ast.ProtoToReferenceInfo(&exprpb.Reference{Value: &exprpb.Constant{}})

Callers

nothing calls this directly

Calls 2

ReferenceInfoToProtoFunction · 0.92
NewIdentReferenceFunction · 0.92

Tested by

no test coverage detected