From 2cfa370b5bdb14869f690d116ef4d493adeb2322 Mon Sep 17 00:00:00 2001 From: Andreas Jonsson Date: Fri, 27 Dec 2024 10:01:50 +0000 Subject: [PATCH] Bug 36025: Selenium test for the query parameters Fix selenium test: 1. Use classname of form instead of no longer existing id 2. Fix test count --- t/db_dependent/selenium/patrons_search.t | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/t/db_dependent/selenium/patrons_search.t b/t/db_dependent/selenium/patrons_search.t index 8aa1673fa9..af1c0b05de 100755 --- a/t/db_dependent/selenium/patrons_search.t +++ b/t/db_dependent/selenium/patrons_search.t @@ -568,7 +568,7 @@ subtest 'Search patrons' => sub { }; subtest 'Search patrons in modal' => sub { - plan tests => 2; + plan tests => 3; setup(); @@ -836,6 +836,8 @@ subtest 'Search patrons in modal' => sub { }; subtest 'no clause for extended_attributes when none are default searchable' => sub { + plan tests => 2; + $attribute_type_searchable_1->update( { searched_by_default => 0 } ); $attribute_type_searchable_2->update( { searched_by_default => 0 } ); @@ -843,7 +845,7 @@ subtest 'Search patrons in modal' => sub { $driver->execute_script( <<'EOF', 'capture_ajax_data' ); jQuery( document ).on( "ajaxSend", function( event, request, settings ) { - jQuery('#patron_search_form').after('
'); + jQuery('.patron_search_form').after('
'); var url = new URL(window.location.origin + settings.url); var parts = url.search.substring(1).split('&'); var q; @@ -860,7 +862,7 @@ jQuery( document ).on( "ajaxSend", function( event, request, settings ) { for (var j = 0; q0 && j < q0.length; j++) { for (var k = 0; k < q0[j].length; k++) { if (q0[j][k].hasOwnProperty('extended_attributes.code')) { - jQuery('#patron_search_form').after('
'); + jQuery('.patron_search_form').after('
'); } } } -- 2.39.5