From 16af1961b606b6d5e4706172fb75c517ac4f7ae6 Mon Sep 17 00:00:00 2001 From: David Gustafsson Date: Wed, 24 Sep 2025 16:18:35 +0200 Subject: [PATCH] Bug 40869: Fix tests and documentation after changing argument name --- Koha/UI/Form/Builder/Item.pm | 2 +- t/db_dependent/Koha/UI/Form/Builder/Item.t | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Koha/UI/Form/Builder/Item.pm b/Koha/UI/Form/Builder/Item.pm index a23ccb335ee..96fe98c0a0f 100644 --- a/Koha/UI/Form/Builder/Item.pm +++ b/Koha/UI/Form/Builder/Item.pm @@ -454,7 +454,7 @@ Flag to add an empty option to the library list. =item ignore_non_mandatory_invisible_subfields -Skip the subfields that are not visible on the editor. +Skip the non mandatory subfields that are not visible in the editor. When duplicating an item we do not want to retrieve the subfields that are hidden. diff --git a/t/db_dependent/Koha/UI/Form/Builder/Item.t b/t/db_dependent/Koha/UI/Form/Builder/Item.t index 7a90485648c..3043a526a2d 100755 --- a/t/db_dependent/Koha/UI/Form/Builder/Item.t +++ b/t/db_dependent/Koha/UI/Form/Builder/Item.t @@ -325,7 +325,7 @@ subtest 'subfields_to_allow & ignore_not_allowed_subfields' => sub { is( $subfield, undef, "subfield that is not in the allow list is not returned" ); }; -subtest 'ignore_invisible_subfields' => sub { +subtest 'ignore_non_mandatory_invisible_subfields' => sub { plan tests => 2; my $biblio = @@ -351,11 +351,11 @@ subtest 'ignore_invisible_subfields' => sub { biblionumber => $biblio->biblionumber, item => $item->unblessed, } - )->edit_form( { ignore_invisible_subfields => 1 } ); + )->edit_form( { ignore_non_mandatory_invisible_subfields => 1 } ); ($subfield) = grep { $_->{subfield} eq 'l' } @$subfields; is( $subfield->{marc_value}->{value}, - undef, 'items.issues not copied if ignore_invisible_subfields is passed' + undef, 'items.issues not copied if ignore_non_mandatory_invisible_subfields is passed' ); }; -- 2.49.0