From d1b5a9f5bb4a28e86fbd2f3c0ca3127a98d2d4d9 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 10 Aug 2017 15:02:23 -0300 Subject: [PATCH] Bug 19042: Add mock IndependentBranches=0 for the other test These tests do not cover correctly getletter, but it is not the goal of this patch. Superlibrarian behaviour must be tested as well. Signed-off-by: Jonathan Druart Signed-off-by: Jonathan Druart (cherry picked from commit e3dafbfccd06af8fca45fada449e93e3d0616cd6) Signed-off-by: Fridolin Somers --- t/db_dependent/Letters.t | 1 + 1 file changed, 1 insertion(+) diff --git a/t/db_dependent/Letters.t b/t/db_dependent/Letters.t index c0a8a5d7eb..a08603bcf3 100644 --- a/t/db_dependent/Letters.t +++ b/t/db_dependent/Letters.t @@ -184,6 +184,7 @@ is( $letters->[0]->{name}, 'my name', 'GetLetters gets the name correctly' ); # getletter subtest 'getletter' => sub { plan tests => 16; + t::lib::Mocks::mock_preference('IndependentBranches', 0); my $letter = C4::Letters::getletter('my module', 'my code', $library->{branchcode}, 'email'); is( $letter->{branchcode}, $library->{branchcode}, 'GetLetters gets the branch code correctly' ); is( $letter->{module}, 'my module', 'GetLetters gets the module correctly' ); -- 2.39.2