From 38833892099b086e4360991d4098f91ca4eef661 Mon Sep 17 00:00:00 2001 From: schiwaa Date: Wed, 12 Jun 2024 15:39:45 +0200 Subject: [PATCH] tests pass with identifyers adapted to kebab style --- frontend-e2e/cypress/e2e/florilegium_cb.cy.js | 4 ++-- .../cypress/e2e/guests_privileges.cy.js | 20 +++++++++---------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/frontend-e2e/cypress/e2e/florilegium_cb.cy.js b/frontend-e2e/cypress/e2e/florilegium_cb.cy.js index 21f13fb2..7e1b2c8b 100644 --- a/frontend-e2e/cypress/e2e/florilegium_cb.cy.js +++ b/frontend-e2e/cypress/e2e/florilegium_cb.cy.js @@ -30,8 +30,8 @@ describe("'Florilegium Coislinianum B' has the right owner and witnesses", funct .contains(expectedName) .click(); cy.get('#tradition-name').contains(expectedName); - cy.get('#sidebar_properties').contains('user@example.org'); + cy.get('#sidebar-properties').contains('user@example.org'); // Sort the witness list for better reliability - cy.get('#sidebar_properties').contains('A, B, C, D, E, F, G, H, K, P, Q, S, T'); + cy.get('#sidebar-properties').contains('A, B, C, D, E, F, G, H, K, P, Q, S, T'); }); }); \ No newline at end of file diff --git a/frontend-e2e/cypress/e2e/guests_privileges.cy.js b/frontend-e2e/cypress/e2e/guests_privileges.cy.js index 89cf5b2b..6d012fa5 100644 --- a/frontend-e2e/cypress/e2e/guests_privileges.cy.js +++ b/frontend-e2e/cypress/e2e/guests_privileges.cy.js @@ -119,7 +119,7 @@ describe('A guest should not be offered to "Edit Collation" of any tradition', ( // un-skip when issue solved, re-tag 'issue' to 'passes': describe('A guest should not be offered to edit Properties', () => { it.skip('issue #170, #157', () => { - cy.get('#sidebar_properties').find('h6').find('svg').should('not.be.visible'); + cy.get('#sidebar-properties').find('h6').find('svg').should('not.be.visible'); }); }); @@ -152,7 +152,7 @@ describe('A guest should be offered to download a public "Tradition"', () => { cy.log('title: ' + tradition.title); // click through all traditions cy.get('#traditions-list').contains(tradition.title).click(); - cy. get('#stemma_buttons').contains(label).should('be.visible').and('be.enabled'); + cy. get('#stemma-buttons').contains(label).should('be.visible').and('be.enabled'); // TODO test functionality }); }); @@ -194,9 +194,9 @@ describe('A guest should be offered to "Examine Stemma" of a public tradition on // TODO?: assert the stemma's correct Witnesses // 'Examine Stemma' - cy.get('#stemma_buttons').contains(label_examine).should('be.visible').and('be.enabled'); + cy.get('#stemma-buttons').contains(label_examine).should('be.visible').and('be.enabled'); // 'Download Stemma' in all available formats. - cy.get('#stemma_buttons').find('#stemma_image_downloadbtn').contains(label_download_stemma).as('download_stemma_button').should('be.visible').and('be.enabled'); + cy.get('#stemma-buttons').find('#stemma_image_downloadbtn').contains(label_download_stemma).as('download_stemma_button').should('be.visible').and('be.enabled'); cy.get('@download_stemma_button').click(); // cy.get('@download_stemma_button').parent().find('a').should('have.length', 3); // TODO: which formats are availabel? // TODO: test functionality @@ -210,14 +210,14 @@ describe('A guest should be offered to "Examine Stemma" of a public tradition on cy.get('#tradition_info').contains('Stemma').should('not.exist'); // no 'Examine Stemma' offered - // cy.get('#stemma_buttons').contains(label_examine); // TODO remove line, write issue - cy.get('#stemma_buttons').contains('TODO: ' + label_examine).should('not.exist'); // TODO eventually: remove and use next line instead - // cy.get('#stemma_buttons').contains(label_examine).should('not.be.enabled'); // or .should('not.exist') + // cy.get('#stemma-buttons').contains(label_examine); // TODO remove line, write issue + cy.get('#stemma-buttons').contains('TODO: ' + label_examine).should('not.exist'); // TODO eventually: remove and use next line instead + // cy.get('#stemma-buttons').contains(label_examine).should('not.be.enabled'); // or .should('not.exist') // no 'Download Stemma' offered - // cy.get('#stemma_buttons').find('#stemma_image_downloadbtn').contains(label_download_stemma); // TODO remove line, write issue - cy.get('#stemma_buttons').find('#stemma_image_downloadbtn').contains('TODO: ' + label_download_stemma).should('not.exist'); // TODO eventually: remove and use next line instead - // cy.get('#stemma_buttons').find('#stemma_image_downloadbtn').contains(label_download_stemma).should('not.be.enabled'); // or .should('not.exist') + // cy.get('#stemma-buttons').find('#stemma_image_downloadbtn').contains(label_download_stemma); // TODO remove line, write issue + cy.get('#stemma-buttons').find('#stemma_image_downloadbtn').contains('TODO: ' + label_download_stemma).should('not.exist'); // TODO eventually: remove and use next line instead + // cy.get('#stemma-buttons').find('#stemma_image_downloadbtn').contains(label_download_stemma).should('not.be.enabled'); // or .should('not.exist') } }); });