Commit cd5e529
committed
test(coverage): exercise extractTool/extractExternalTools error paths
Adds tests that mock process.smol.mount to drive:
- extractTool: mount-rejection wrapped as "failed to extract … from the SEA VFS"
for both npm-package (cdxgen) and standalone-binary (sfw) tools
- extractExternalTools: null returns for non-SEA mode, missing mount,
and max-depth recursion guard
dlx/vfs-extract.mts: 17.97% → 28.11% statements (14.95% → 28.97% branch).
Remaining gap (~70%) is the lock-file / extraction-recursion / TOCTOU
loop body — would require a real SEA build with process.smol or
heavy filesystem-state harnessing to exercise.1 parent 105fe04 commit cd5e529
1 file changed
Lines changed: 33 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
26 | 27 | | |
27 | 28 | | |
28 | 29 | | |
| |||
243 | 244 | | |
244 | 245 | | |
245 | 246 | | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
246 | 279 | | |
0 commit comments