Skip to content

Commit

Permalink
Warn when runTestsOnSaveFilter is set to a blank string
Browse files Browse the repository at this point in the history
  • Loading branch information
tacheometry committed Dec 29, 2022
1 parent 8723baf commit 046b018
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions extension/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@ const refreshFsWatcher = () => {
if (!getRunTestsOnSavePreference()) return;

const glob = getGlobPatternPreference();
if (glob === "")
return vscode.window.showWarningMessage(
'The runTestsOnSaveFilter has been set to "". The extension won\'t be able to detect any files changes; consider removing the property entirely for the default value to be used, or including a glob that captures the desired file names.'
);

fsWatcher = vscode.workspace.createFileSystemWatcher(
glob,
false,
Expand Down

0 comments on commit 046b018

Please sign in to comment.