microsoft / vscode-test-cli

Command-line runner for VS Code tests
MIT License
19 stars 7 forks source link

Fix Resolve in bin.mts #10

Closed JustinGrote closed 7 months ago

JustinGrote commented 7 months ago

CC @connor4312

bin.mts is an ES module, but tries to use require.resolve which is only available to CommonJS modules. This generates a requires so things work properly. The future option is to use import.meta.requires if it ever goes stable. This type of resolution is also generally not necessary, passing through the relative paths works fine as well.