From dd8f10783347d882cdfa7f0fed4515813d074575 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 3 Jul 2025 14:01:51 +0200 Subject: [PATCH] Bug 40301: (bug 40299 follow-up) Add Cypress tests --- .../KohaTable/CirculationHistory_spec.ts | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 t/cypress/integration/KohaTable/CirculationHistory_spec.ts diff --git a/t/cypress/integration/KohaTable/CirculationHistory_spec.ts b/t/cypress/integration/KohaTable/CirculationHistory_spec.ts new file mode 100644 index 00000000000..401ca93c7b0 --- /dev/null +++ b/t/cypress/integration/KohaTable/CirculationHistory_spec.ts @@ -0,0 +1,23 @@ +describe("members/readingrec", () => { + const table_id = "table_readingrec"; + beforeEach(() => { + cy.login(); + cy.title().should("eq", "Koha staff interface"); + cy.task("insertSampleCheckout").then(objects_checkout => { + cy.wrap(objects_checkout).as("objects_checkout"); + }); + }); + + afterEach(function () { + cy.task("deleteSampleObjects", [this.objects_checkout]); + }); + + it("'Type' column should be hidden", function () { + cy.visit( + `/cgi-bin/koha/members/readingrec.pl?borrowernumber=${this.objects_checkout.patron.patron_id}` + ); + + cy.get(`#${table_id} th`).contains("Type").should("not.exist"); + cy.get(`#${table_id} th:first`).contains("Date"); + }); +}); -- 2.34.1