ReferenceError: Cypress/Cy is not defined #26130
Unanswered
johnsonkandul-github
asked this question in
Questions and Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have created new JS file called as email.js under cypress/support directory along side command.js, e2e.js, index.js files.
Cypress version is latest 12.7.0.
I am trying to use cy.task(it is registered in cypress.config.js setupnodes events) or Cypress.config('baseURL') but getting below errors
Sample Errors :
I have tried to import cypress using const Cypress = require("cypress"); however no luck.
I am wondering why cypress() cy() works fines in js files under e2e and support folders without importing cypress
I have also tried to create new .eslintrc.json file and added below code but still no luck
{
"plugins": [
"cypress"
]
}
Beta Was this translation helpful? Give feedback.
All reactions