(t *testing.T)
| 7 | ) |
| 8 | |
| 9 | func TestOptions(t *testing.T) { |
| 10 | t.Run("WithFuncs", func(t *testing.T) { |
| 11 | fc := execution.DefaultFuncCollection.Copy() |
| 12 | opts := execution.NewOptions(execution.WithFuncs(fc)) |
| 13 | if _, ok := opts.Funcs.Get("len"); !ok { |
| 14 | t.Error("expected funcs to contain 'len'") |
| 15 | } |
| 16 | }) |
| 17 | |
| 18 | t.Run("WithoutUnstable", func(t *testing.T) { |
| 19 | opts := execution.NewOptions(execution.WithUnstable(), execution.WithoutUnstable()) |
| 20 | if opts.Unstable { |
| 21 | t.Error("expected unstable to be false") |
| 22 | } |
| 23 | }) |
| 24 | } |
| 25 | |
| 26 | func TestFuncCollection(t *testing.T) { |
| 27 | t.Run("Copy", func(t *testing.T) { |
nothing calls this directly
no test coverage detected