running a simple command using vs code terminal for cypress automation 1 time its showing actual results while executing with npx cypress open command and using npx cypress run showing different results from the previous test result.
here is my test suit
describe('My FIrst Test', () =>
{
it('verify title-Positive', () => {
cy.visit("https://ubitelehealth.com/")// steps
cy.title().should('eq','Discreet Care for Sexual Health & Hair Loss - UBI Telehealth')
})
it('verify title-Negative', () => {
cy.visit("https://ubitelehealth.com/")// steps
cy.title().should('eq','strokealert91123')
})
})
here is error .
(Results)
Tests: 2 Passing: 0 Failing: 2 Pending: 0 Skipped: 0 Screenshots: 2 Video: false Duration: 30 seconds Spec Ran: 1sttest.cy.js
while the same suit runing with npx cypress open gives different results
i run a test suit using 2 different commands
npx cypress open it is passing one result and failing other one.
while npx cypress run fails both of the tests or scripts
Husnain Zafar is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.