(t *testing.T, b []byte, kind string)
| 57 | } |
| 58 | |
| 59 | func assertParseSingleFile(t *testing.T, b []byte, kind string) *File { |
| 60 | files, _, err := Parse(bytes.NewReader(b)) |
| 61 | if err != nil { |
| 62 | t.Fatalf("failed to parse %s: %v", kind, err) |
| 63 | } |
| 64 | if len(files) != 1 { |
| 65 | t.Fatalf("expected %s to contain a single files, but found %d", kind, len(files)) |
| 66 | } |
| 67 | return files[0] |
| 68 | } |
| 69 | |
| 70 | func assertFilesEqual(t *testing.T, expected, actual *File) { |
| 71 | assertEqual(t, expected.OldName, actual.OldName, "OldName") |
no test coverage detected