https://cypress.io logo
So it looks like <@715580668045951047> was correct...
# e2e-testing
g
So it looks like @gray-kilobyte-89541 was correct in pointed out I was only spying on the url and not stubbing the response. And thanks for the course: @gray-kilobyte-89541 , I went through everything and it has some good content. I now have this code which does not seem to need the
cy.wait()
command I was using in an earlier implementation: `describe('visit and interact with home page', () => { const apiURL =
${Cypress.env('apiUrl')}
it('visit and interact with home page', () => { cy.intercept('GET',
${apiURL}/*
, { statusCode: 200, body: { data: { id: '1', }, }, }).as('getApi') cy.intercept('POST',
http://localhost:8545*
, { statusCode: 200, body: { data: { id: '1', }, }, }).as('post8545') // cy.wait('@getApi') cy.visit('/') }) })` Still refactoring this, but the test is passing and the routes display that they are stubbed like they should.