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

Function fnEnvOption

tools/celtest/test_runner_test.go:175–182  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

173}
174
175func fnEnvOption() cel.EnvOption {
176 return cel.Function("fn",
177 cel.Overload("fn_int", []*cel.Type{cel.IntType}, cel.IntType,
178 cel.UnaryBinding(func(in ref.Val) ref.Val {
179 i := in.(types.Int)
180 return i / types.Int(2)
181 })))
182}
183
184// TestTriggerTests tests different scenarios of the TriggerTestsFromCompiler function.
185func TestTriggerTests(t *testing.T) {

Callers 3

TestCoverageStatsFunction · 0.85
setupTestsFunction · 0.85

Calls 4

FunctionFunction · 0.92
OverloadFunction · 0.92
UnaryBindingFunction · 0.92
IntTypeAlias · 0.92

Tested by

no test coverage detected