Bugzilla – Attachment 181258 Details for
Bug 39473
Drop-down filters on item holdings table should match codes exactly
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 39473: Add Cypress tests
Bug-39473-Add-Cypress-tests.patch (text/plain), 1.93 KB, created by
Jonathan Druart
on 2025-04-22 12:44:09 UTC
(
hide
)
Description:
Bug 39473: Add Cypress tests
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2025-04-22 12:44:09 UTC
Size:
1.93 KB
patch
obsolete
>From e44a364c671ebfcda0793c3098658ef2156b09a7 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Tue, 22 Apr 2025 14:40:42 +0200 >Subject: [PATCH] Bug 39473: Add Cypress tests > >--- > .../integration/KohaTable/Holdings_spec.ts | 25 +++++++++++++++++++ > 1 file changed, 25 insertions(+) > >diff --git a/t/cypress/integration/KohaTable/Holdings_spec.ts b/t/cypress/integration/KohaTable/Holdings_spec.ts >index 869d01e136d..ad194d9b158 100644 >--- a/t/cypress/integration/KohaTable/Holdings_spec.ts >+++ b/t/cypress/integration/KohaTable/Holdings_spec.ts >@@ -362,6 +362,31 @@ describe("catalogue/detail/holdings_table", () => { > new RegExp(`"me.item_type_id":\\["${item_type_id}"\\]`) > ); > }); >+ >+ cy.get(`#${table_id}_wrapper input.dt-input`).clear(); >+ // Show filters if not there already >+ cy.get(`.${table_id}_table_controls .show_filters`).then(link => { >+ if (link.is(":visible")) { >+ cy.wrap(link).click(); >+ cy.wait("@searchItems"); >+ } >+ }); >+ // Select first (non-empty) option >+ cy.get(`#${table_id}_wrapper th#holdings_itype select`).then( >+ select => { >+ item_type_id = select.find("option").eq(1).val(); >+ expect(item_type_id).to.match(/^\^/); >+ expect(item_type_id).to.match(/\$$/); >+ cy.wrap(select).select(item_type_id); >+ item_type_id = item_type_id.replace(/^\^|\$$/g, ""); // remove ^ and $ >+ } >+ ); >+ cy.wait("@searchItems").then(interception => { >+ const q = interception.request.query.q; >+ expect(q).to.match( >+ new RegExp(`{"me.item_type_id":"${item_type_id}"}`) >+ ); >+ }); > }); > }); > }); >-- >2.34.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 39473
:
181258
|
181259
|
181268
|
181570
|
181571
|
182109
|
182110