it('adds users to the group', function() {
// Add other user to the group
cy.get('[data-cy=group-member-add]').click();
- cy.get('[data-cy=form-dialog]')
- .should('contain', 'Add users')
+ cy.get('.sharing-dialog')
+ .should('contain', 'Sharing settings')
.within(() => {
- cy.get('input').type("other");
+ cy.get('[data-cy=invite-people-field] input').type("other");
});
- cy.contains('Other User').click();
- cy.get('[data-cy=form-dialog] button[type=submit]').click();
+ cy.get('[role=tooltip]').click();
+ cy.get('.sharing-dialog').contains('Save').click();
// Check that both users are present with appropriate permissions
cy.get('[data-cy=group-members-data-explorer]')
.contains('Other User')
.parents('tr')
.within(() => {
- cy.get('[data-cy=user-hidden-checkbox]').click();
+ cy.get('[data-cy=user-visible-checkbox]').click();
});
// Check that other user is visible
cy.get('[data-cy=group-details-permissions-tab]').click();
.contains('Other User')
.parents('tr')
.within(() => {
- cy.get('[data-cy=user-hidden-checkbox]').click();
+ cy.get('[data-cy=user-visible-checkbox]').click();
});
// Check that other user is hidden
cy.get('[data-cy=group-details-permissions-tab]').click();
cy.get('[data-cy=group-members-data-explorer]')
.within(() => {
cy.get('[data-cy=group-member-add]').should('not.exist');
- cy.get('[data-cy=user-hidden-checkbox] input').should('be.disabled');
+ cy.get('[data-cy=user-visible-checkbox] input').should('be.disabled');
cy.get('[data-cy=resource-delete-button]').should('be.disabled');
cy.get('[data-cy=edit-permission-button]').should('not.exist');
});