Bug 12086: qa-followup: remove warning on launching unit tests

Without this patch, the following warning appears:
  t/db_dependent/Holds/RevertWaitingStatus.t .. Subroutine
  C4::Context::userenv redefined at
  t/db_dependent/Holds/RevertWaitingStatus.t line 25.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This commit is contained in:
Jonathan Druart 2014-06-23 11:43:48 +02:00 committed by Tomas Cohen Arazi
parent 0f6ff54104
commit a717931d7d

View file

@ -22,6 +22,7 @@ $dbh->{RaiseError} = 1;
$dbh->do("DELETE FROM reserves");
$dbh->do("DELETE FROM old_reserves");
local $SIG{__WARN__} = sub { warn $_[0] unless $_[0] =~ /redefined/ };
*C4::Context::userenv = \&Mock_userenv;
sub Mock_userenv {