question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to specify configuration in lerna repo with hoisted packages

See original GitHub issue

I’ve got a lerna repo with packages/* packages and apps/* packages. In one of my apps, I’ve added cypress and cypress-cucumber-preprocessor. When I go through the example, I’m able to get my .feature file detected by the cypress runner, but when I execute it, it doesn’t detect any step definitions.

I added some logs to see where the issue might be, and I can see that the cosmiconfig is not finding any configuration even though I’ve tried adding the section to package.json as well as in an external file. I suspect the issue is with the fact that the cosmiconfig package has been hoisted out of my app directory’s node_modules and put into the root node_modules.

Is there some other way to configure the preprocessor without relying on cosmiconfig, or alternatively, “dumping” all the paths that the tool searches for step definitions in order to just put them in the right place without configuration?

Please let me know if you require additional info.

Thanks.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
lgandeckicommented, Mar 6, 2019

Thank you for kind words @akatechis ! Feel free using this space if you need any help. 😃

1reaction
akatechiscommented, Mar 5, 2019

Finally figured this out, I was iterating on the phrase in my feature file, and without realizing it, the matcher in the step definition did not match what was in the feature file.

Apologies for taking up your time, and thank you so much for such an awesome tool. I was only recently made aware of cucumber and cypress, and using them together unlocks so many possibilities for us. I’m really excited to get the rest of my team on board with this.

Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Unable to specify configuration in lerna repo with hoisted ...
I've got a lerna repo with packages/* packages and apps/* packages. In one of my apps, I've added cypress and cypress-cucumber-preprocessor.
Read more >
Managing Monorepo using Lerna and Yarn workspaces
This section describes the way to use Lerna and Yarn Workspaces to manage Monorepo. Settings. First, you have to set the private and...
Read more >
nohoist in Workspaces | Yarn Blog
yarn workspaces can share modules across child projects/packages by hoisting them up to their parent project's node_modules: monorepo/ ...
Read more >
A guide through The Wild Wild West of setting up a mono repo ...
This will create a lerna.json configuration file as well as a packages folder, ... They can't be hoisted in the root config because...
Read more >
Integrating Nx and Lerna
it runs commands for a single package or multiple packages ( lerna run ) ... If you are about to set up a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found