(t *testing.T)
| 805 | } |
| 806 | |
| 807 | func TestCheck_AllowUndefinedVariables(t *testing.T) { |
| 808 | type Env struct { |
| 809 | A int |
| 810 | } |
| 811 | |
| 812 | tree, err := parser.Parse(`Any + fn()`) |
| 813 | require.NoError(t, err) |
| 814 | |
| 815 | config := conf.New(Env{}) |
| 816 | expr.AllowUndefinedVariables()(config) |
| 817 | |
| 818 | _, err = checker.Check(tree, config) |
| 819 | assert.NoError(t, err) |
| 820 | } |
| 821 | |
| 822 | func TestCheck_AllowUndefinedVariables_DefaultType(t *testing.T) { |
| 823 | env := map[string]bool{} |
nothing calls this directly
no test coverage detected
searching dependent graphs…