Skip to content

Instantly share code, notes, and snippets.

@jessesanders
Created December 7, 2018 19:22
Show Gist options
  • Save jessesanders/a4cac61296155f2de508f3e98353c888 to your computer and use it in GitHub Desktop.
Save jessesanders/a4cac61296155f2de508f3e98353c888 to your computer and use it in GitHub Desktop.
A simple cypress stubbed response example
cy.server(); // start the server
cy.route({
method: "GET", // Route all GET requests
url: "/users/*", // that have a URL that matches '/users/*'
response: [] // and force the response to be: []
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment