Bugzilla – Attachment 55426 Details for
Bug 16851
Move HasOverdues to Koha::Patron->has_overdues
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 16851 [QA Followup] - Fix Unit Tests
Bug-16851-QA-Followup---Fix-Unit-Tests.patch (text/plain), 1.74 KB, created by
Kyle M Hall (khall)
on 2016-09-09 11:21:44 UTC
(
hide
)
Description:
Bug 16851 [QA Followup] - Fix Unit Tests
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2016-09-09 11:21:44 UTC
Size:
1.74 KB
patch
obsolete
>From bbdc1dfec720caa4869655901bb6f5e9e7b2a531 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Fri, 9 Sep 2016 10:21:33 +0000 >Subject: [PATCH] Bug 16851 [QA Followup] - Fix Unit Tests > >--- > t/db_dependent/Koha/Patrons.t | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) > >diff --git a/t/db_dependent/Koha/Patrons.t b/t/db_dependent/Koha/Patrons.t >index 345f530..f18e207 100644 >--- a/t/db_dependent/Koha/Patrons.t >+++ b/t/db_dependent/Koha/Patrons.t >@@ -19,7 +19,7 @@ > > use Modern::Perl; > >-use Test::More tests => 7; >+use Test::More tests => 8; > use Test::Warn; > > use C4::Circulation; >@@ -128,14 +128,14 @@ subtest 'has_overdues' => sub { > is( $retrieved_patron->has_overdues, 0, ); > > my $tomorrow = DateTime->today( time_zone => C4::Context->tz() )->add( days => 1 ); >- my $issue = AddIssue( $new_patron_1->unblessed, $item_1->{barcode} ); >+ my $issue = Koha::Issue->new({ borrowernumber => $new_patron_1->id, itemnumber => $item_1->{itemnumber}, date_due => $tomorrow, branchcode => $library->{branchcode} })->store(); > is( $retrieved_patron->has_overdues, 0, ); >- AddReturn( $item_1->{barcode} ); >+ $issue->delete(); > my $yesterday = DateTime->today(time_zone => C4::Context->tz())->add( days => -1 ); >- $issue = AddIssue( $new_patron_1->unblessed, $item_1->{barcode}, $yesterday ); >+ $issue = Koha::Issue->new({ borrowernumber => $new_patron_1->id, itemnumber => $item_1->{itemnumber}, date_due => $yesterday, branchcode => $library->{branchcode} })->store(); > $retrieved_patron = Koha::Patrons->find( $new_patron_1->borrowernumber ); > is( $retrieved_patron->has_overdues, 1, ); >- AddReturn( $item_1->{barcode} ); >+ $issue->delete(); > }; > > subtest 'update_password' => sub { >-- >2.1.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 16851
:
53094
|
53325
|
53511
|
53996
|
55190
|
55425
| 55426