[open-ils-commits] ***SPAM*** [GIT] Evergreen ILS branch master updated. 600b50819530a66b8e5260e579efc64634708017

Evergreen Git git at git.evergreen-ils.org
Mon Nov 10 21:20:31 EST 2014


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  600b50819530a66b8e5260e579efc64634708017 (commit)
       via  af4686075df25a85ad60905a4f4266ff6c800059 (commit)
      from  afe883fc8cc0d6883ef839868c367a3c30cbd8e1 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 600b50819530a66b8e5260e579efc64634708017
Author: Jason Etheridge <jason at esilibrary.com>
Date:   Fri Nov 7 13:38:39 2014 -0500

    LP#1386260: DST bugs in perl live tests (04-overdue_with_closed_dates.t)
    
    more fixes
    
    Signed-off-by: Jason Etheridge <jason at esilibrary.com>
    Signed-off-by: Ben Shum <bshum at biblio.org>

diff --git a/Open-ILS/src/perlmods/live_t/04-overdue_with_closed_dates.t b/Open-ILS/src/perlmods/live_t/04-overdue_with_closed_dates.t
index e00496e..739fe26 100644
--- a/Open-ILS/src/perlmods/live_t/04-overdue_with_closed_dates.t
+++ b/Open-ILS/src/perlmods/live_t/04-overdue_with_closed_dates.t
@@ -21,22 +21,14 @@ use OpenSRF::Utils qw/cleanse_ISO8601/;
 our $apputils   = "OpenILS::Application::AppUtils";
 
 sub create_closed_date {
-    my $ten_days = OpenSRF::Utils->interval_to_seconds('240 h 0 m 0 s');
-    my $almost_twenty_four_hours = OpenSRF::Utils->interval_to_seconds('23 h 59 m 59 s');
-    #$circ->due_date( $apputils->epoch2ISO8601($due_date - $twenty_days) );
-
     my $aoucd = Fieldmapper::actor::org_unit::closed_date->new;
     $aoucd->org_unit(WORKSTATION_LIB);
     $aoucd->reason('04-overdue_with_closed_dates.t');
     $aoucd->close_start(
-        $apputils->epoch2ISO8601(
-            DateTime->today()->epoch() - $ten_days
-        )
+        DateTime->today()->subtract( days => 10 )->iso8601()
     );
     $aoucd->close_end(
-        $apputils->epoch2ISO8601(
-            DateTime->today()->epoch() - $ten_days + $almost_twenty_four_hours
-        )
+        DateTime->today()->subtract( days => 9 )->subtract( seconds => 1 )->iso8601()
     );
     my $resp = $apputils->simplereq(
         'open-ils.actor',
@@ -202,13 +194,12 @@ if (my $bill_resp = $bill_req->recv) {
     }
 }
 
-my $xact_start = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->xact_start))->epoch;
-my $due_date = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->due_date))->epoch;
-my $twenty_days = OpenSRF::Utils->interval_to_seconds('480 h 0 m 0 s');
+my $xact_start = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->xact_start));
+my $due_date = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->due_date));
 
 # Rewrite history; technically we should rewrite status_changed_item on the copy as well, but, meh...
-$circ->xact_start( $apputils->epoch2ISO8601($xact_start - $twenty_days) );
-$circ->due_date( $apputils->epoch2ISO8601($due_date - $twenty_days) );
+$circ->xact_start( $xact_start->subtract( days => 20 )->iso8601() );
+$circ->due_date( $due_date->subtract( days => 20 )->iso8601() );
 
 $cstore_ses->connect; # need stateful connection
 my $xact = $cstore_ses->request('open-ils.cstore.transaction.begin')->gather(1);

commit af4686075df25a85ad60905a4f4266ff6c800059
Author: Jason Etheridge <jason at esilibrary.com>
Date:   Fri Nov 7 13:00:10 2014 -0500

    LP#1386260: DST bugs in perl live tests (03-overdue_circ.t)
    
    Use safer date math to handle bug with DST
    
    Signed-off-by: Jason Etheridge <jason at esilibrary.com>
    Signed-off-by: Ben Shum <bshum at biblio.org>

diff --git a/Open-ILS/src/perlmods/live_t/03-overdue_circ.t b/Open-ILS/src/perlmods/live_t/03-overdue_circ.t
index 7981d32..fd83b2c 100644
--- a/Open-ILS/src/perlmods/live_t/03-overdue_circ.t
+++ b/Open-ILS/src/perlmods/live_t/03-overdue_circ.t
@@ -145,13 +145,12 @@ if (my $bill_resp = $bill_req->recv) {
     }
 }
 
-my $xact_start = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->xact_start))->epoch;
-my $due_date = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->due_date))->epoch;
-my $twenty_days = OpenSRF::Utils->interval_to_seconds('480 h 0 m 0 s');
+my $xact_start = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->xact_start));
+my $due_date = DateTime::Format::ISO8601->parse_datetime(cleanse_ISO8601($circ->due_date));
 
 # Rewrite history; technically we should rewrite status_changed_item on the copy as well, but, meh...
-$circ->xact_start( $apputils->epoch2ISO8601($xact_start - $twenty_days) );
-$circ->due_date( $apputils->epoch2ISO8601($due_date - $twenty_days) );
+$circ->xact_start( $xact_start->subtract( days => 20 )->iso8601() );
+$circ->due_date( $due_date->subtract( days => 20 )->iso8601() );
 
 $cstore_ses->connect; # need stateful connection
 my $xact = $cstore_ses->request('open-ils.cstore.transaction.begin')->gather(1);

-----------------------------------------------------------------------

Summary of changes:
 Open-ILS/src/perlmods/live_t/03-overdue_circ.t     |    9 +++----
 .../perlmods/live_t/04-overdue_with_closed_dates.t |   21 +++++--------------
 2 files changed, 10 insertions(+), 20 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list