X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/d2817690f88befb0c306e637d6e87367016c76e3..d1fa1c888be0d956178cc29cd78dbb924a7606c1:/cypress/integration/sharing.spec.js diff --git a/cypress/integration/sharing.spec.js b/cypress/integration/sharing.spec.js index 5786c41d..5a297136 100644 --- a/cypress/integration/sharing.spec.js +++ b/cypress/integration/sharing.spec.js @@ -74,8 +74,34 @@ describe('Sharing tests', function () { cy.get('[data-cy=context-menu]').should('contain', 'Move to trash'); cy.get('[data-cy=context-menu]').contains('Move to trash').click(); + // GUARD: Let's wait for the above removed project to disappear + // before continuing, to avoid intermittent failures. + cy.get('main').should('not.contain', mySharedWritableProject.name); + cy.get('main').contains(mySharedReadonlyProject.name).rightclick(); cy.get('[data-cy=context-menu]').should('not.contain', 'Move to trash'); }); }); + + it('can edit project in shared with me', () => { + cy.createProject({ + owningUser: adminUser, + targetUser: activeUser, + projectName: 'mySharedWritableProject', + canWrite: true, + addToFavorites: true + }); + + cy.getAll('@mySharedWritableProject') + .then(function ([mySharedWritableProject]) { + cy.loginAs(activeUser); + + cy.get('[data-cy=side-panel-tree]').contains('Shared with me').click(); + + const newProjectName = `New project name ${mySharedWritableProject.name}`; + const newProjectDescription = `New project description ${mySharedWritableProject.name}`; + + cy.testEditProjectOrCollection('main', mySharedWritableProject.name, newProjectName, newProjectDescription); + }); + }); }); \ No newline at end of file