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>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 8e1b6f76d6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
This commit is contained in:
parent
7cba916cef
commit
00a42d6167
|
|
@ -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 {
|
||||
|
|
|
|||
Loading…
Reference in New Issue