Balrog994 / cucumber-test-runner

An Extension for Visual Studio Code to Run and Debug CucumberJS Tests
MIT License
4 stars 6 forks source link

Runner doesn't handle spaces in feature file paths #20

Open laurence79 opened 3 months ago

laurence79 commented 3 months ago

When attempting to run tests in files with spaces in the paths, the runner gets confused.

I think this is because the paths aren't escaped here so cucumber.js think they're separate arguments.

e.g. output

Running cucumber-cli...
Working Directory: /Users/xxx/xxx
node ./node_modules/@cucumber/cucumber/bin/cucumber.js /Users/lxxx/xxx/src/features/With Space.feature:5 --format message 

We could naively surround each file:line in quotes, or use something like the ancient node-shell-escape.

Excellent extension by the way. I'm happy to work up a PR to address this?