Bug 25791: Remove win.print()
[koha.git] / t / db_dependent / Patroncards.t
blob3f9b742e31123ccf7f18cf71f50dd6098b1a3a0c
1 #!/usr/bin/perl
3 # This file is part of Koha.
5 # Koha is free software; you can redistribute it and/or modify it under the
6 # terms of the GNU General Public License as published by the Free Software
7 # Foundation; either version 3 of the License, or (at your option) any later
8 # version.
10 # Koha is distributed in the hope that it will be useful, but WITHOUT ANY
11 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
12 # A PARTICULAR PURPOSE. See the GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License along
15 # with Koha; if not, see <http://www.gnu.org/licenses>.
17 use Modern::Perl;
18 use Test::More tests => 1;
19 use Test::MockModule;
20 use t::lib::Mocks;
21 use t::lib::TestBuilder;
23 use C4::Patroncards::Layout;
25 subtest '->save' => sub {
26 plan tests => 1;
27 my $layout = C4::Patroncards::Layout->new(
28 layout_name => "new patron card",
29 layout_id => '', # The interface send an empty string
30 layout_xml => 'some_xml'
32 my $layout_id = $layout->save;
33 ok($layout_id > 0, 'A layout_id should have been returned on ->save');