From 8feffbf4c4d1fe443167d0f40271b8ec477c0e20 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Daniel=20Kuty=C5=82a?= Date: Mon, 29 Nov 2021 18:06:24 +0100 Subject: [PATCH] 18482: Fixed info icon issue and added cypress test MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Arvados-DCO-1.1-Signed-off-by: Daniel Kutyła --- cypress/integration/project.spec.js | 15 +++++++++++++++ .../main-content-bar/main-content-bar.tsx | 4 ++-- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/cypress/integration/project.spec.js b/cypress/integration/project.spec.js index af2d93e3..1c175952 100644 --- a/cypress/integration/project.spec.js +++ b/cypress/integration/project.spec.js @@ -179,4 +179,19 @@ describe('Project tests', function() { cy.get('[data-cy=not-found-page]').should('not.exist'); }); }); + + it('shows details panel when clicking on the info icon', () => { + cy.createGroup(activeUser.token, { + name: `Test root project ${Math.floor(Math.random() * 999999)}`, + group_class: 'project', + }).as('testRootProject').then(function(testRootProject) { + cy.loginAs(activeUser); + + cy.get('[data-cy=side-panel-tree]').contains(testRootProject.name).click(); + + cy.get('[data-cy=additional-info-icon]').click(); + + cy.contains(testRootProject.uuid).should('exist'); + }); + }); }); \ No newline at end of file diff --git a/src/views-components/main-content-bar/main-content-bar.tsx b/src/views-components/main-content-bar/main-content-bar.tsx index 10ae1790..480150cb 100644 --- a/src/views-components/main-content-bar/main-content-bar.tsx +++ b/src/views-components/main-content-bar/main-content-bar.tsx @@ -60,7 +60,7 @@ export const MainContentBar = buttonVisible: isButtonVisible(state), projectUuid: state.detailsPanel.resourceUuid, }), (dispatch) => ({ - onDetailsPanelToggle: toggleDetailsPanel, + onDetailsPanelToggle: () => dispatch(toggleDetailsPanel()), onRefreshButtonClick: (id) => { dispatch(loadSidePanelTreeProjects(id)); dispatch(reloadProjectMatchingUuid([id])); @@ -80,7 +80,7 @@ export const MainContentBar = {props.buttonVisible && - + } -- 2.30.2