Bugzilla – Attachment 43071 Details for
Bug 14522
Use Koha::Cache for accessing single_holidays()
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14522 [QA Followup]
Bug-14522-QA-Followup.patch (text/plain), 1.71 KB, created by
Kyle M Hall (khall)
on 2015-10-02 15:02:25 UTC
(
hide
)
Description:
Bug 14522 [QA Followup]
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2015-10-02 15:02:25 UTC
Size:
1.71 KB
patch
obsolete
>From f9140a46e242856a6b8a8b4b2d171fa478d79564 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Fri, 2 Oct 2015 11:01:19 -0400 >Subject: [PATCH] Bug 14522 [QA Followup] > >* Change POD to a brief comment >* Fix UT so it doesn't fail on Sundays >--- > Koha/Calendar.pm | 24 +++++++----------------- > t/db_dependent/Holidays.t | 3 +++ > 2 files changed, 10 insertions(+), 17 deletions(-) > >diff --git a/Koha/Calendar.pm b/Koha/Calendar.pm >index be2a6c8..383b092 100644 >--- a/Koha/Calendar.pm >+++ b/Koha/Calendar.pm >@@ -95,23 +95,13 @@ sub single_holidays { > my $cache = Koha::Cache->get_instance(); > my $single_holidays = $cache->get_from_cache('single_holidays'); > >-=for >-$single_holidays looks like this.. >- >-\ { >- CPL [ >- [0] 20131122, >- [1] 20131123, >- [2] 20131124 >- ], >- MPL [ >- [0] 20131122, >- [1] 20131123, >- [2] 20131124 >- ] >-} >- >-=cut >+ # $single_holidays looks like: >+ # { >+ # CPL => [ >+ # [0] 20131122, >+ # ... >+ # ], >+ # } > > unless ($single_holidays) { > my $dbh = C4::Context->dbh; >diff --git a/t/db_dependent/Holidays.t b/t/db_dependent/Holidays.t >index e1bf910..fb9b1fa 100755 >--- a/t/db_dependent/Holidays.t >+++ b/t/db_dependent/Holidays.t >@@ -97,6 +97,9 @@ is( $koha_calendar->is_holiday($monday), 0, 'Monday is not a closed day' ); > is( $koha_calendar->is_holiday($christmas), 1, 'Christmas is a closed day' ); > is( $koha_calendar->is_holiday($newyear), 1, 'New Years day is a closed day' ); > >+$dbh->do("DELETE FROM repeatable_holidays"); >+$dbh->do("DELETE FROM special_holidays"); >+ > my $custom_holiday = DateTime->new( > year => 2013, > month => 11, >-- >1.7.2.5
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 14522
:
41050
|
42255
|
42851
|
42855
|
42856
|
42887
|
42888
|
42919
|
42920
|
42921
|
42922
|
42926
|
43070
| 43071