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.

Require doesn't resolve from the expected path.

See original GitHub issue

In a file inside cypress/support/step_definitions I require a file ./bla. When I view the network tab of the devtools I see this error:

(function () {
  Cypress.action("spec:script:error", {
    type: "BUNDLE_ERROR",
    error: "Error: Cannot find module './bla' from '<project-path>/cypress/integration'{newline}"
  })
}())

I expect it to resolve from cypress/support/step_definitions and not cypress/integration

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
vlavellacommented, Jun 7, 2018

I’m currently under this issue too. I’m working with the v 1.0.0. I can’t figure it out why this is happening

Read more comments on GitHub >

github_iconTop Results From Across the Web

NodeJS path.resolve doesn't work as expected - Stack Overflow
resolve ("D:") , it returns my Node.js project's root directory, which is D:\Docs\NodeJS\DBTest in my case, and it seems strange to me. But ......
Read more >
Issues - GitHub
require.resolve() acts like require() , but returns the resolved path, instead of the actual module. The paths argument is supposed to be ...
Read more >
Auto-mapping doesn't work as expected in an Office 365 ...
Describes an issue in which a mailbox can't map automatically in Office 365 hybrid environment. Provides a resolution.
Read more >
Connect a wireless game controller to your Apple device
Connect a wireless Xbox, PlayStation, or other Bluetooth game controller to your iPhone, iPad, Apple TV, or Mac.
Read more >
Mental Phenomena Don't Map Into the Brain as Expected
The Brain Doesn't Think the Way You Think It Does ... those categories and the neural networks that support them don't work as...
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