Bug 32484: (QA follow-up) Polishing unit test

Test plan, removed done_testing.
License.
Since we are in t/db, good to add transaction, although we currently
do not change anything here. But who knows?

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Marcel de Rooy 2023-04-18 12:33:47 +00:00 committed by Tomas Cohen Arazi
parent f5af35a085
commit bc5a6e8d55
Signed by: tomascohen
GPG key ID: 0A272EA1B2F3C15F

View file

@ -1,8 +1,23 @@
#!/usr/bin/perl
# This file is part of Koha
#
# Koha is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# Koha is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Koha; if not, see <http://www.gnu.org/licenses>.
use Modern::Perl;
use Test::More;
use Test::More tests => 7;
use C4::ClassSource;
@ -11,6 +26,9 @@ use Koha::DateUtils qw( dt_from_string );
use Koha::ItemTypes;
use Koha::Libraries;
my $schema = Koha::Database->new->schema;
$schema->storage->txn_begin;
use_ok('Koha::UI::Form::Builder::Biblio');
subtest 'generate_subfield_form default value' => sub {
@ -179,4 +197,4 @@ subtest 'generate_subfield_form framework plugin' => sub {
like($subfield->{marc_value}->{javascript}, qr,<script>.*</script>,s);
};
done_testing();
$schema->storage->txn_rollback;