You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using the VSCode Cucumber plugin within a Typescript project that imports common shared steps from a Typescript npm module that is packaged as Javascript.
The plugin is able to successfully locate step definitions in Typescript from the local src code, but it fails to locate the shared Javascript steps from the dependency. This seems to be due to the regular expression for matching Javascript step definitions not working for Javascript files that were transpiled down from Typescript. Here's an example of what one of my steps looks like after it has been built into Javascript:
This seemed like it could be fixed by overriding TSX's defineStepDefinitionQueriesvalue in the Javascript implementation to look for Given|When|Then|Given)|When)|Then) however I get Invalid regular expression: Unmatched ')' errors when testing with it even if I try to escape the parentheses. I wasn't really sure what else to try in this case.
👓 What did you see?
I am using the VSCode Cucumber plugin within a Typescript project that imports common shared steps from a Typescript npm module that is packaged as Javascript.
The plugin is able to successfully locate step definitions in Typescript from the local src code, but it fails to locate the shared Javascript steps from the dependency. This seems to be due to the regular expression for matching Javascript step definitions not working for Javascript files that were transpiled down from Typescript. Here's an example of what one of my steps looks like after it has been built into Javascript:
This seemed like it could be fixed by overriding TSX's
defineStepDefinitionQueries
value in the Javascript implementation to look forGiven|When|Then|Given)|When)|Then)
however I getInvalid regular expression: Unmatched ')'
errors when testing with it even if I try to escape the parentheses. I wasn't really sure what else to try in this case.Any help would be greatly appreciated!
✅ What did you expect to see?
Expected the plugin to find the Javascript steps.
📦 Which tool/library version are you using?
🔬 How could we reproduce it?
Steps to reproduce the behavior:
📚 Any additional context?
This text was originally generated from a template, then edited by hand. You can modify the template here.
The text was updated successfully, but these errors were encountered: