(t *testing.T)
| 363 | } |
| 364 | |
| 365 | func TestGetCommitDartFiles_NonDartFiles(t *testing.T) { |
| 366 | tmpDir := t.TempDir() |
| 367 | setupGitRepo(t, tmpDir) |
| 368 | |
| 369 | // Create and commit non-.dart files |
| 370 | createFile(t, tmpDir, "test.go", "package main") |
| 371 | gitAdd(t, tmpDir, "test.go") |
| 372 | commitID := gitCommitAndGetSHA(t, tmpDir, "Add go file") |
| 373 | |
| 374 | // Get files from commit |
| 375 | files, err := GetCommitDartFiles(tmpDir, commitID) |
| 376 | |
| 377 | require.NoError(t, err) |
| 378 | g := testhelpers.TextGoldie(t) |
| 379 | g.Assert(t, t.Name(), []byte(normalizeFilePaths(tmpDir, files))) |
| 380 | } |
| 381 | |
| 382 | func TestGetCommitDartFiles_InvalidCommit(t *testing.T) { |
| 383 | tmpDir := t.TempDir() |
nothing calls this directly
no test coverage detected