(t *testing.T)
| 519 | } |
| 520 | |
| 521 | func TestConstantBlockEval(t *testing.T) { |
| 522 | cb := &constantBlock{ |
| 523 | expr: interpreter.NewConstValue(2, types.IntOne), |
| 524 | } |
| 525 | res := cb.Eval(cel.NoVars()) |
| 526 | if res.Equal(types.IntOne) != types.True { |
| 527 | t.Errorf("cb.Eval() = %v, wanted 1", res) |
| 528 | } |
| 529 | } |
| 530 | |
| 531 | func BenchmarkBlockEval(b *testing.B) { |
| 532 | fac := ast.NewExprFactory() |
nothing calls this directly
no test coverage detected