Skip to content

Commit

Permalink
Make test watching more thorough and accurate
Browse files Browse the repository at this point in the history
  • Loading branch information
brettcannon committed May 11, 2024
1 parent 98cb863 commit 8b6c873
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
9 changes: 1 addition & 8 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,8 @@
"problemMatcher": [],
"label": "npm: test:watch",
// https://crates.io/crates/watchexec-cli
"detail": "watchexec --watch tests \"npx pta tests/*.mjs\"",
"detail": "watchexec --watch <tests>",
"isBackground": true
},
{
"label": "all:watch",
"isBackground": true,
"group": "build",
"type": "shell",
"command": "watchexec --exts res \"npx rescript build && npx pta tests/*.mjs\""
}
]
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"res:clean": "rescript clean",
"res:dev": "rescript -w",
"test": "pta tests/*.mjs",
"test:watch": "watchexec --filter \"tests/*.res\" \"npx pta tests/*.mjs\"",
"test:watch": "watchexec --watch src --watch tests --exts mjs --no-vsc-ignore \"npx pta tests/*.mjs\"",
"format": "rescript format -all",
"package": "esbuild src/Index.res.mjs --outfile=dist/index.js --bundle --platform=node --target=node20",
"all": "npm run res:build && npm run test && npm run format && npm run package"
Expand Down

0 comments on commit 8b6c873

Please sign in to comment.