I have been trying to understand the cypress file & folder structure when used with cucumber and vue.js but it's been driving me crazy, especially when different sources say different things. My problem is I wrote the following test: screenshot of source code and browser element inspection
This is the Cypress output
When I open my website locally on chrome, I see clearly that the title element has been changed. Why is test in cypress still not passing when it should?
CodePudding user response:
it has been like this for most ide that are online the title appears when you just don't use third party tools like cypress and use a normal ide and save it on the file running without running and saving using other sites online.... even if you open and take a look at the code using CTRL SHIFT I it will show you the code and there you can clearly see that the title haven't been changed
CodePudding user response:
For checking the title you have to use cy.title()
. So in your case it would be:
cy.title().should('eq', 'User Registration')