Bug 40372: Remove warning from api/v1/holds.t
t/db_dependent/api/v1/holds.t .. 1/16 No reserves HOLD_CANCELLATION letter transported by email at /kohadevbox/koha/C4/Letters.pm line 602.
We do not test the notification here, we can simply ignore the letters
code
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit c14e72e782)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
This commit is contained in:
parent
7566ed0d99
commit
98b97ea075
|
|
@ -17,7 +17,8 @@
|
|||
|
||||
use Modern::Perl;
|
||||
|
||||
use Test::More tests => 16;
|
||||
use Test::More tests => 17;
|
||||
use Test::NoWarnings;
|
||||
use Test::MockModule;
|
||||
use Test::Mojo;
|
||||
use t::lib::TestBuilder;
|
||||
|
|
@ -199,6 +200,10 @@ subtest "Test endpoints with permission" => sub {
|
|||
|
||||
plan tests => 45;
|
||||
|
||||
# Prevent warning 'No reserves HOLD_CANCELLATION letter transported by email'
|
||||
my $mock_letters = Test::MockModule->new('C4::Letters');
|
||||
$mock_letters->mock( 'GetPreparedLetter', sub { return } );
|
||||
|
||||
$t->get_ok("//$userid_1:$password@/api/v1/holds")->status_is(200)->json_has('/0')->json_has('/1')->json_hasnt('/2');
|
||||
|
||||
$t->get_ok("//$userid_1:$password@/api/v1/holds?priority=2")->status_is(200)
|
||||
|
|
|
|||
Loading…
Reference in New Issue