Skip to content

Commit

Permalink
chore: check for the presense of files in watch mode (#5508)
Browse files Browse the repository at this point in the history
  • Loading branch information
sheremet-va committed Apr 8, 2024
1 parent b72fbfc commit 7b306fe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/vitest/src/node/core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -832,7 +832,7 @@ export class Vitest {
return

const heedsRerun = this.handleFileChanged(i.file)
if (heedsRerun)
if (heedsRerun.length)
rerun = true
})
}
Expand All @@ -841,7 +841,7 @@ export class Vitest {
files.push(filepath)
}

return files
return Array.from(new Set(files))
}

private async reportCoverage(allTestsRun: boolean) {
Expand Down

0 comments on commit 7b306fe

Please sign in to comment.