Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cy.route() is wrongly matching urls other than url defined (throwing status on other url) #84

Closed
jennifer-shehane opened this issue Nov 23, 2015 · 1 comment

Comments

@jennifer-shehane
Copy link
Member

If I define .route() and pass in a status BEFORE another .route() defined in short form (which should always defaults to status: 200), my shorthand route actually ends up being the status of the previously defined route (which is incorrect).

Example Code

  it "foos [2a4]", ->
    cy
      .server()
      .route({
          method: "GET"
          url: /answers/
          status: 503
          response: {}
        })
      .route(/forms/, "fixture:form_requires_asset").as("getForm")
      .wait("@getForm").then ->
         expect(true).to.be.true

Command Log
screen shot 2015-11-23 at 2 14 06 pm

@brian-mann
Copy link
Member

Fixed in 0.12.6.

@cypress-io cypress-io locked as resolved and limited conversation to collaborators Dec 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants