Changeset View
Changeset View
Standalone View
Standalone View
cypress/support/index.js
Show First 20 Lines • Show All 54 Lines • ▼ Show 20 Lines | |||||
Cypress.Commands.add('ambassadorLogin', () => { | Cypress.Commands.add('ambassadorLogin', () => { | ||||
return loginUser('ambassador', 'ambassador'); | return loginUser('ambassador', 'ambassador'); | ||||
}); | }); | ||||
Cypress.Commands.add('depositLogin', () => { | Cypress.Commands.add('depositLogin', () => { | ||||
return loginUser('deposit', 'deposit'); | return loginUser('deposit', 'deposit'); | ||||
}); | }); | ||||
Cypress.Commands.add('addForgeModeratorLogin', () => { | |||||
ardumont: that's a pain to type in the ui login form to connect though ¯\_(ツ)_/¯ ;) | |||||
Done Inline Actionsyes but you only need to do it once as you can save the credentials in your browser. anlambert: yes but you only need to do it once as you can save the credentials in your browser. | |||||
return loginUser('add-forge-moderator', 'add-forge-moderator'); | |||||
}); | |||||
function mockCostlyRequests() { | function mockCostlyRequests() { | ||||
cy.intercept('https://status.softwareheritage.org/**', { | cy.intercept('https://status.softwareheritage.org/**', { | ||||
body: { | body: { | ||||
'result': { | 'result': { | ||||
'status': [ | 'status': [ | ||||
{ | { | ||||
'id': '5f7c4c567f50b304c1e7bd5f', | 'id': '5f7c4c567f50b304c1e7bd5f', | ||||
'name': 'Save Code Now', | 'name': 'Save Code Now', | ||||
Show All 29 Lines |
that's a pain to type in the ui login form to connect though ¯\_(ツ)_/¯ ;)