Bug 19042: Silence warnings t/db_dependent/Letters.t

TEST PLAN
---------
prove t/db_dependent/Letters.t
-- there will be a message: "C4::Context->userenv not defined!"
apply this patch
prove t/db_dependent/Letters.t
-- there will no longer be that message.
run qa test tools

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Mark Tompsett 2017-08-04 14:24:38 -04:00 committed by Jonathan Druart
parent e35903574c
commit d01ce104a7

View file

@ -196,7 +196,9 @@ subtest 'getletter' => sub {
my $context = Test::MockModule->new('C4::Context');
$context->mock( 'userenv', sub {
return { branch => "anotherlib" }
return {
flags => 1,
branch => "anotherlib" }
});
t::lib::Mocks::mock_preference('IndependentBranches', 1);