[Koha-bugs] [Bug 7804] Add Koha Plugin System

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Jan 16 03:26:48 CET 2013


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7804

Jared Camins-Esakov <jcamins at cpbibliography.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|Signed Off                  |Failed QA

--- Comment #71 from Jared Camins-Esakov <jcamins at cpbibliography.com> ---
We are definitely getting closer. However, I have found some issues that will
need to be addressed:
1) Koha::Plugins cannot be used without a koha-conf.xml file that is configured
to enable plugins. That's a problem! The check needs to be done at run-time
rather than compile time.
2) The unit test in t/Plugins.t is data dependent. It would be much better to
mock the configuration data. Barring that, the test should be moved to
t/db_dependent.
3) The test adds '.' to @INC. Unfortunately, tests are not usually run from t/,
so it always fails when I run prove t/. The solution is to get the directory
component from __FILE__
4) The test fails spectacularly for me:
jcamins at kohadev:~/kohaclone/t$ perl Plugins.t                                   
1..15
ok 1 - use Koha::Plugins;
ok 2 - use Koha::Plugins::Handler;
not ok 3 - use Koha::Plugins::Base;
#   Failed test 'use Koha::Plugins::Base;'
#   at Plugins.t line 18.#     Tried to use 'Koha::Plugins::Base'.
#     Error:  Undefined subroutine &main::/home/jcamins/koha-dev/plugins called
at (eval 37) line 2.
#       ...propagated at /usr/share/perl/5.14/base.pm line 93.
# BEGIN failed--compilation aborted at
/usr/share/perl5/Authen/CAS/Client/Response.pm line 68.
# Compilation failed in require at /usr/share/perl5/Authen/CAS/Client.pm line
8.
# BEGIN failed--compilation aborted at /usr/share/perl5/Authen/CAS/Client.pm
line 8.
# Compilation failed in require at /home/jcamins/kohaclone/C4/Auth_with_cas.pm
line 26.
# BEGIN failed--compilation aborted at
/home/jcamins/kohaclone/C4/Auth_with_cas.pm line 26.
# Compilation failed in require at /home/jcamins/kohaclone/C4/Auth.pm line 54.
# BEGIN failed--compilation aborted at /home/jcamins/kohaclone/C4/Auth.pm line
63.
# Compilation failed in require at /home/jcamins/kohaclone/Koha/Plugins/Base.pm
line 27.
# BEGIN failed--compilation aborted at
/home/jcamins/kohaclone/Koha/Plugins/Base.pm line 27.
# Compilation failed in require at (eval 34) line 2.
# BEGIN failed--compilation aborted at (eval 34) line 2.
not ok 4 - use Koha::Plugin::Test;
#   Failed test 'use Koha::Plugin::Test;'
#   at Plugins.t line 19.
#     Tried to use 'Koha::Plugin::Test'.
#     Error:  Attempt to reload Koha/Plugins/Base.pm aborted.
# Compilation failed in require at (eval 39) line 2.
#       ...propagated at /usr/share/perl/5.14/base.pm line 93.
# BEGIN failed--compilation aborted at Koha/Plugin/Test.pm line 7.
# Compilation failed in require at (eval 38) line 2.
# BEGIN failed--compilation aborted at (eval 38) line 2.
not ok 5 - Test can_load
#   Failed test 'Test can_load'
#   at Plugins.t line 22.
Can't locate object method "new" via package "Koha::Plugin::Test" at Plugins.t
line 24.
# Looks like you planned 15 tests but ran 5.
# Looks like you failed 3 tests of 5 run.
# Looks like your test exited with 2 just after 5.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list