[ARVADOS-WORKBENCH2] updated: 2.3.0-46-g75f4aa52

Git user git at public.arvados.org
Wed Dec 1 19:31:17 UTC 2021


Summary of changes:
 cypress/integration/group-manage.spec.js         | 31 ++++++++++++++++++++++--
 src/views-components/data-explorer/renderers.tsx |  2 +-
 2 files changed, 30 insertions(+), 3 deletions(-)

       via  75f4aa52ad828eab58e43ea99bdded98b1a87aa1 (commit)
      from  2c257e34488b251e146631e12559732b3879d567 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 75f4aa52ad828eab58e43ea99bdded98b1a87aa1
Author: Stephen Smith <stephen at curii.com>
Date:   Wed Dec 1 14:30:57 2021 -0500

    18123: Add test for resources shared with group.
    
    Arvados-DCO-1.1-Signed-off-by: Stephen Smith <stephen at curii.com>

diff --git a/cypress/integration/group-manage.spec.js b/cypress/integration/group-manage.spec.js
index b317ad3c..14abcd2d 100644
--- a/cypress/integration/group-manage.spec.js
+++ b/cypress/integration/group-manage.spec.js
@@ -104,7 +104,7 @@ describe('Group manage tests', function() {
             });
     });
 
-    it('unhides users', function() {
+    it('can unhide and re-hide users', function() {
         // Must use admin user to have manage permission on user
         cy.loginAs(adminUser);
         cy.get('[data-cy=side-panel-tree]').contains('Groups').click();
@@ -145,9 +145,36 @@ describe('Group manage tests', function() {
             .should('not.contain', 'Other User')
     });
 
-    it('removes users from the group', function() {
+    it('displays resources shared with the group', function() {
+        // Switch to activeUser
         cy.loginAs(activeUser);
         cy.get('[data-cy=side-panel-tree]').contains('Groups').click();
+
+        // Get groupUuid and create shared project
+        cy.get('[data-cy=groups-panel-data-explorer]')
+            .contains(groupName)
+            .parents('tr')
+            .find('[data-cy=uuid]')
+            .invoke('text')
+            .as('groupUuid')
+            .then((groupUuid) => {
+                cy.createProject({
+                    owningUser: activeUser,
+                    projectName: 'test-project',
+                }).as('testProject').then((testProject) => {
+                    cy.shareWith(activeUser.token, groupUuid, testProject.uuid, 'can_read');
+                });
+            });
+
+        // Check that the project is listed in permissions
+        cy.get('[data-cy=groups-panel-data-explorer]').contains(groupName).click();
+        cy.get('[data-cy=group-details-permissions-tab]').click();
+        cy.get('[data-cy=group-permissions-data-explorer]')
+            .contains('test-project');
+    });
+
+    it('removes users from the group', function() {
+        cy.get('[data-cy=side-panel-tree]').contains('Groups').click();
         cy.get('[data-cy=groups-panel-data-explorer]').contains(groupName).click();
 
         // Remove other user
diff --git a/src/views-components/data-explorer/renderers.tsx b/src/views-components/data-explorer/renderers.tsx
index e87c9f33..a13269e5 100644
--- a/src/views-components/data-explorer/renderers.tsx
+++ b/src/views-components/data-explorer/renderers.tsx
@@ -171,7 +171,7 @@ export const ResourceFullName = connect(
 
 
 const renderUuid = (item: { uuid: string }) =>
-    <Typography noWrap>{item.uuid}</Typography>;
+    <Typography data-cy="uuid" noWrap>{item.uuid}</Typography>;
 
 export const ResourceUuid = connect(
     (state: RootState, props: { uuid: string }) => {

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list