Bugzilla – Attachment 53717 Details for
Bug 16586
Koha Plugins: Limit results of GetPlugins by metadata
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 16586: [QA Follow-up] Add test for two metadata conditions
Bug-16586-QA-Follow-up-Add-test-for-two-metadata-c.patch (text/plain), 1.46 KB, created by
Marcel de Rooy
on 2016-07-26 12:04:24 UTC
(
hide
)
Description:
Bug 16586: [QA Follow-up] Add test for two metadata conditions
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2016-07-26 12:04:24 UTC
Size:
1.46 KB
patch
obsolete
>From c33b6e768bb57b3101afaf7f4913684795589d54 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Tue, 26 Jul 2016 13:54:31 +0200 >Subject: [PATCH] Bug 16586: [QA Follow-up] Add test for two metadata > conditions >Content-Type: text/plain; charset=utf-8 > >Run the test and see.. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > t/db_dependent/Plugins.t | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) > >diff --git a/t/db_dependent/Plugins.t b/t/db_dependent/Plugins.t >index f918693..92a6f8c 100755 >--- a/t/db_dependent/Plugins.t >+++ b/t/db_dependent/Plugins.t >@@ -3,7 +3,7 @@ > use strict; > use warnings; > >-use Test::More tests => 23; >+use Test::More tests => 24; > use File::Basename; > use FindBin qw($Bin); > use Archive::Extract; >@@ -53,6 +53,12 @@ is( scalar grep( /^Test Plugin$/, @names), 1, "Koha::Plugins::GetPlugins functio > }); > @names = map { $_->get_metadata()->{'name'} } @plugins; > is( scalar grep( /^Test Plugin$/, @names), 1, "GetPlugins also found Test Plugin via a metadata tag" ); >+# Test two metadata conditions; one does not exist for Test.pm >+# Since it is a required key, we should not find the same results >+my @plugins2 = Koha::Plugins->new({ enable_plugins => 1 })->GetPlugins({ >+ metadata => { my_example_tag => 'find_me', not_there => '1' }, >+}); >+isnt( scalar @plugins2, scalar @plugins, 'GetPlugins with two metadata conditions' ); > > SKIP: { > my $plugins_dir = C4::Context->config("pluginsdir"); >-- >1.7.10.4
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 16586
:
51771
|
53544
|
53691
|
53692
| 53717 |
53718
|
53747
|
53748