diff --git a/test/cypress/support/commands.js b/test/cypress/support/commands.js index 28a8aa979..e7f8cb9d9 100755 --- a/test/cypress/support/commands.js +++ b/test/cypress/support/commands.js @@ -38,6 +38,15 @@ Cypress.Commands.add('login', (user) => { }, }).then((response) => { window.localStorage.setItem('token', response.body.token); + cy.request({ + method: 'GET', + url: '/api/VnUsers/ShareToken', + headers: { + Authorization: window.localStorage.getItem('token'), + }, + }).then(({ body }) => { + window.localStorage.setItem('tokenMultimedia', body.multimediaToken.id); + }); }); });