Bugzilla – Attachment 125258 Details for
Bug 28906
Koha::Items->filter_by_visible_in_opac doesn't honour list context
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28906: Regression tests
Bug-28906-Regression-tests.patch (text/plain), 1.40 KB, created by
Martin Renvoize (ashimema)
on 2021-09-24 15:12:11 UTC
(
hide
)
Description:
Bug 28906: Regression tests
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2021-09-24 15:12:11 UTC
Size:
1.40 KB
patch
obsolete
>From f7b4a2bb791b93ffc084910c4bf3855055a6fddd Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Thu, 26 Aug 2021 09:34:39 -0300 >Subject: [PATCH] Bug 28906: Regression tests > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >Signed-off-by: David Nind <david@davidnind.com> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > t/db_dependent/Koha/Items.t | 11 ++++++++++- > 1 file changed, 10 insertions(+), 1 deletion(-) > >diff --git a/t/db_dependent/Koha/Items.t b/t/db_dependent/Koha/Items.t >index d743402b1a1..0d34f8f721d 100755 >--- a/t/db_dependent/Koha/Items.t >+++ b/t/db_dependent/Koha/Items.t >@@ -1535,7 +1535,7 @@ $schema->storage->txn_rollback; > > subtest 'filter_by_visible_in_opac() tests' => sub { > >- plan tests => 12; >+ plan tests => 14; > > $schema->storage->txn_begin; > >@@ -1688,6 +1688,15 @@ subtest 'filter_by_visible_in_opac() tests' => sub { > my @warnings = C4::Context->dbh->selectrow_array('SHOW WARNINGS'); > is( $warnings[2], q{Truncated incorrect DOUBLE value: 'AB'}); > >+ $rules = { itype => [ $itype_1->itemtype ], copynumber => [ 2 ] }; >+ my @items = $biblio->items->filter_by_visible_in_opac; >+ is( >+ scalar @items, >+ 2, >+ 'filter_by_visible_in_opac honours list context' >+ ); >+ is( ref($items[0]), 'Koha::Item', 'Returns a list of Koha::Item objects' ); >+ > $schema->storage->txn_rollback; > }; > >-- >2.20.1
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 28906
:
124112
|
124113
|
124114
|
124115
|
125035
|
125036
|
125037
| 125258 |
125259
|
125260