Bugzilla – Attachment 145270 Details for
Bug 32622
Auth.t failing on D10
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 32622: Fix Auth.t on D10
Bug-32622-Fix-Autht-on-D10.patch (text/plain), 1.76 KB, created by
Martin Renvoize
on 2023-01-13 13:15:05 UTC
(
hide
)
Description:
Bug 32622: Fix Auth.t on D10
Filename:
MIME Type:
Creator:
Martin Renvoize
Created:
2023-01-13 13:15:05 UTC
Size:
1.76 KB
patch
obsolete
>From bd29dfcc1b660de423e6f408d374d07ce7763145 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Fri, 13 Jan 2023 12:15:15 +0100 >Subject: [PATCH] Bug 32622: Fix Auth.t on D10 > >It's caused by a version mismatch of Test::MockModule with D10, >which does not have this commit: https://github.com/geofffranks/test-mockmodule/commit/fef9e742e45e2437e3449eea9970d70555d44bff > >We should remove the chaining here. > >Test plan: >Confirm that Auth.t still pass, and is fixed on D10 > >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > t/db_dependent/Auth.t | 8 +++++--- > 1 file changed, 5 insertions(+), 3 deletions(-) > >diff --git a/t/db_dependent/Auth.t b/t/db_dependent/Auth.t >index d0ef2a60a29..8c816c4da6b 100755 >--- a/t/db_dependent/Auth.t >+++ b/t/db_dependent/Auth.t >@@ -171,9 +171,11 @@ subtest 'checkauth() tests' => sub { > my ( $return ) = C4::Auth::check_cookie_auth( $sessionID, undef, { skip_version_check => 1, remote_addr => '1.2.3.4' } ); > is( $return, 'ok', 'Former session in shape now' ); > >- my $mock1 = Test::MockModule->new('C4::Auth')->mock( 'safe_exit', sub {} ); >- my $mock2 = Test::MockModule->new('CGI') ->mock( 'request_method', 'POST' ) >- ->mock( 'cookie', sub { return $sessionID; } ); # oversimplified.. >+ my $mock1 = Test::MockModule->new('C4::Auth'); >+ $mock1->mock( 'safe_exit', sub {} ); >+ my $mock2 = Test::MockModule->new('CGI'); >+ $mock2->mock( 'request_method', 'POST' ); >+ $mock2->mock( 'cookie', sub { return $sessionID; } ); # oversimplified.. > my $cgi = CGI->new; > my $password = 'Incr3d1blyZtr@ng93$'; > $patron2->set_password({ password => $password }); >-- >2.39.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 32622
:
145262
| 145270