Skip to content

Commit

Permalink
fix workbenches dropdown issue
Browse files Browse the repository at this point in the history
  • Loading branch information
FedeAlonso committed Dec 20, 2024
1 parent cda65db commit 69850f2
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
13 changes: 13 additions & 0 deletions frontend/src/__tests__/cypress/cypress/pages/workbench.ts
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,19 @@ class AttachExistingStorageModal extends Modal {
cy.findByTestId('persistent-storage-typeahead').contains(name).click();
}

verifyPSDropdownIsDisabled(): void {
cy.get('[data-testid="persistent-storage-group"] .pf-v6-c-menu-toggle')
.should('have.class', 'pf-m-disabled')
.and('have.attr', 'disabled');
}

verifyPSDropdownText(expectedText: string): void {
cy.get('[data-testid="persistent-storage-group"] .pf-v6-c-text-input-group__text-input').should(
'have.value',
expectedText,
);
}

findStandardPathInput() {
return cy.findByTestId('mount-path-folder-value');
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@ describe('Workbench and PVSs tests', () => {
createSpawnerPage.getNameInput().fill(workbenchName);
createSpawnerPage.findNotebookImage('code-server-notebook').click();
createSpawnerPage.findAttachExistingStorageButton().click();
attachExistingStorageModal.selectExistingPersistentStorage(PVCDisplayName);
attachExistingStorageModal.verifyPSDropdownIsDisabled();
attachExistingStorageModal.verifyPSDropdownText(PVCDisplayName);
attachExistingStorageModal.findStandardPathInput().fill(workbenchName);
attachExistingStorageModal.findAttachButton().click();
createSpawnerPage.findSubmitButton().click();
Expand Down

0 comments on commit 69850f2

Please sign in to comment.