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

Use fixture as request body shortcut #3387

Open
bahmutov opened this Issue Feb 8, 2019 · 1 comment

Comments

2 participants
@bahmutov
Copy link
Collaborator

bahmutov commented Feb 8, 2019

It would be nice to be able to load and send a fixture file by name like

it('finds issues mentioned', function () {
   cy.request('/api', 'fx:pr-opened')
})

Currently, have to load fixture and then send

it('finds issues mentioned', function () {
    cy.fixture('pr-opened')
      .then(data => cy.request('/api', data))
})
@bahmutov

This comment has been minimized.

Copy link
Collaborator Author

bahmutov commented Feb 8, 2019

mirror to cy.route('/api', 'fx:response')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment