mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-15 07:34:42 -04:00
changed calls to cy.route to cy.intercept (#806)
Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
parent
bc7ff07256
commit
e0dbb05572
5 changed files with 87 additions and 49 deletions
|
@ -6,29 +6,32 @@
|
|||
|
||||
describe('profile page', () => {
|
||||
beforeEach(() => {
|
||||
cy.route({
|
||||
cy.intercept({
|
||||
url: '/api/v2/tokens',
|
||||
method: 'GET',
|
||||
response: [
|
||||
method: 'GET'
|
||||
}, {
|
||||
body: [
|
||||
{
|
||||
label: "cypress-App",
|
||||
created: 1601991518
|
||||
}
|
||||
]
|
||||
})
|
||||
cy.route({
|
||||
cy.intercept({
|
||||
url: '/api/v2/tokens',
|
||||
method: 'POST',
|
||||
response: {
|
||||
method: 'POST'
|
||||
}, {
|
||||
body: {
|
||||
label: 'cypress',
|
||||
secret: 'c-y-p-r-e-s-s',
|
||||
created: Date.now()
|
||||
}
|
||||
})
|
||||
cy.route({
|
||||
cy.intercept({
|
||||
url: '/api/v2/tokens/1601991518',
|
||||
method: 'DELETE',
|
||||
response: []
|
||||
method: 'DELETE'
|
||||
}, {
|
||||
body: []
|
||||
})
|
||||
cy.visit('/profile')
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue