(t *testing.T, good []interface{}, bad []interface{})
| 511 | } |
| 512 | |
| 513 | func testGetStructCodec(t *testing.T, good []interface{}, bad []interface{}) { |
| 514 | for _, x := range good { |
| 515 | if _, err := getStructCodec(reflect.TypeOf(x)); err != nil { |
| 516 | t.Errorf("type %T: got non-nil error (%s), want nil", x, err) |
| 517 | } |
| 518 | } |
| 519 | for _, x := range bad { |
| 520 | if _, err := getStructCodec(reflect.TypeOf(x)); err == nil { |
| 521 | t.Errorf("type %T: got nil error, want non-nil", x) |
| 522 | } |
| 523 | } |
| 524 | } |
| 525 | |
| 526 | func TestNilKeyIsStored(t *testing.T) { |
| 527 | x := struct { |
no test coverage detected
searching dependent graphs…