(b *testing.B)
| 9 | ) |
| 10 | |
| 11 | func BenchmarkValueUnder(b *testing.B) { |
| 12 | b.Run("primitive", func(b *testing.B) { |
| 13 | val := super.Null |
| 14 | b.ResetTimer() |
| 15 | for b.Loop() { |
| 16 | val.Under() |
| 17 | } |
| 18 | }) |
| 19 | b.Run("named", func(b *testing.B) { |
| 20 | typ, _ := super.NewContext().LookupTypeNamed("name", super.TypeNull) |
| 21 | val := super.NewValue(typ, nil) |
| 22 | b.ResetTimer() |
| 23 | for b.Loop() { |
| 24 | val.Under() |
| 25 | } |
| 26 | }) |
| 27 | } |
| 28 | |
| 29 | func TestValueValidate(t *testing.T) { |
| 30 | recType := super.NewTypeRecord(0, []super.Field{ |
nothing calls this directly
no test coverage detected