Bugzilla – Attachment 163797 Details for
Bug 35536
Improve removal of Koha plugins in unit tests
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35536: (follow-up) Fix Plugins.t for D10
Bug-35536-follow-up-Fix-Pluginst-for-D10.patch (text/plain), 1.55 KB, created by
Marcel de Rooy
on 2024-03-25 11:59:14 UTC
(
hide
)
Description:
Bug 35536: (follow-up) Fix Plugins.t for D10
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2024-03-25 11:59:14 UTC
Size:
1.55 KB
patch
obsolete
>From e6b80fe8b95c564d2903046a0607aa6c96b4f610 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Mon, 25 Mar 2024 11:56:15 +0000 >Subject: [PATCH] Bug 35536: (follow-up) Fix Plugins.t for D10 >Content-Type: text/plain; charset=utf-8 > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > t/db_dependent/Koha/Plugins/Plugins.t | 9 ++++++--- > 1 file changed, 6 insertions(+), 3 deletions(-) > >diff --git a/t/db_dependent/Koha/Plugins/Plugins.t b/t/db_dependent/Koha/Plugins/Plugins.t >index 1dcd8578b1..1c8f96ab15 100755 >--- a/t/db_dependent/Koha/Plugins/Plugins.t >+++ b/t/db_dependent/Koha/Plugins/Plugins.t >@@ -333,13 +333,16 @@ subtest 'RemovePlugins' => sub { > Koha::Plugins::Method->new( { plugin_class => "$class_basename$i", plugin_method => "testmr$i" } )->store; > > # no_auto => 1 here prevents loading of a not-existing module >- $mocks->[$i] = Test::MockModule->new( "$class_basename$i", no_auto => 1 )->mock( new => 1 ) >- unless $mocks->[$i]; >+ unless ( $mocks->[$i] ) { >+ $mocks->[$i] = Test::MockModule->new( "$class_basename$i", no_auto => 1 ); >+ $mocks->[$i]->mock( new => 1 ); >+ } > } > > # We will (re)create new plugins (without modules) > # This requires mocking can_load from Module::Load::Conditional >- my $mlc_mock = Test::MockModule->new('Koha::Plugins')->mock( can_load => 1 ); >+ my $mlc_mock = Test::MockModule->new('Koha::Plugins'); >+ $mlc_mock->mock( can_load => 1 ); > my $plugin_mocks = []; > my @enabled_plugins; > >-- >2.30.2
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 35536
:
159804
|
159820
|
159821
|
159822
|
159823
|
159824
|
159825
|
159830
|
159839
|
159840
|
159841
|
159842
|
159843
|
159844
|
160024
|
160025
|
160026
|
160027
|
160028
|
160029
|
160030
|
160031
|
160032
|
160801
|
160802
|
160803
|
160804
|
160805
|
160806
|
160807
|
160808
|
160809
|
160817
|
160818
|
160819
|
160820
|
160821
|
160822
|
160823
|
160824
|
160825
|
160881
|
160882
|
160883
|
160884
|
160885
|
160886
|
160887
|
160888
|
160889
|
163701
| 163797