kiwigrid/gherkin-testcafe

Glob pattern not working properly

Closed this issue · 3 comments

Problem

When I try to run my test, I receive the error, that the Step implementation is missing, but it should be covered by the glob pattern.

Enivronment

  • testcafe: 1.6.1
  • gherkin-testcafe: 2.5.0
  • cucumber: 6.0.5

The folder structure:

image

The command I run the tests with:

node -r dotenv/config node_modules/gherkin-testcafe/main.js firefox steps/**/*.js tests/test.feature

The sidebar.js is detected, but all files in steps/*.js are not detected. I also see this when I start the live mode, then TestCafe is only watching for changes in the sidebar.js file.

Hey Daniel,

that sounds weird. Could you try adding steps/*.js to the source files?

Like

node -r dotenv/config node_modules/gherkin-testcafe/main.js firefox steps/**/*.js steps/*.js tests/test.feature

The thing is, we don't really control how this works. We use the glob package for matching the files. So however it works, it works.

Hey Lukas,

thank you for this fast response.

With both pattern it's working.

Ok, good.
So if it is working with both, we just leave this as a workaround instead of changing the behavior here.