From 7c574a9b04a8bf3fb55cd03a5db731fc1f3d5ea8 Mon Sep 17 00:00:00 2001 From: David Cook Date: Thu, 24 Dec 2020 01:43:59 +0000 Subject: [PATCH] Bug 21325: Fix t/db_dependent/Auth.t test This patch fixes some warnings in t/db_dependent/Auth.t. Note that it doesn't add any tests. --- t/db_dependent/Auth.t | 2 ++ 1 file changed, 2 insertions(+) diff --git a/t/db_dependent/Auth.t b/t/db_dependent/Auth.t index afe4ccaa81..8bace24ae9 100755 --- a/t/db_dependent/Auth.t +++ b/t/db_dependent/Auth.t @@ -52,6 +52,7 @@ subtest 'checkauth() tests' => sub { } ); $cgi->mock( 'cookie', sub { return; } ); + $cgi->mock( 'request_method', sub { return 'POST' } ); my $authnotrequired = 1; my ( $userid, $cookie, $sessionID, $flags ) = C4::Auth::checkauth( $cgi, $authnotrequired ); @@ -68,6 +69,7 @@ subtest 'checkauth() tests' => sub { elsif ( $param eq 'password' ) { return $db_user_pass; } else { return; } }); + $cgi->mock( 'request_method', sub { return 'POST' } ); ( $userid, $cookie, $sessionID, $flags ) = C4::Auth::checkauth( $cgi, $authnotrequired ); is ( $userid, undef, 'If DB user is used, it should not be logged in' ); -- 2.11.0