From 5dec610776dc122316dcbe6049e630fc367046fd Mon Sep 17 00:00:00 2001 From: Alex Arnaud Date: Thu, 1 Mar 2018 08:43:41 +0000 Subject: [PATCH] Bug 20340 - Ability to add and use authentication plugins Plugins must be placed in and enabled with AuthenticationModule system preference. Test plan: - Apply this patch, - set UseKohaPlugins to enabled, - define a pluginsdir in your koha-conf.xml, - put a plugin in this directory. - I.e, take the one provided in tests directory: - t/Koha/Plugin/TestAuth.pm, - login/pass is test/test - You should have: /your/plugins/dir/Koha/Plugin/TestAuth.pm, - test authentication with and without the plugin. --- t/Koha/Plugin/TestAuth.pm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/t/Koha/Plugin/TestAuth.pm b/t/Koha/Plugin/TestAuth.pm index 6d449e9..86d7483 100644 --- a/t/Koha/Plugin/TestAuth.pm +++ b/t/Koha/Plugin/TestAuth.pm @@ -38,6 +38,11 @@ sub new { return $self; } +sub configure { + my ($self, $args) = @_; + $self->go_home(); +} + =head2 retrieve_data Just return priority. It overrides the one in Koha::Plugin::Base for the test. @@ -53,11 +58,6 @@ sub retrieve_data { } -sub configure { - my ($self, $args) = @_; - $self->go_home(); -} - =head2 checkpw ($result, cardnumber, $userid) = -- 2.7.4