[freeside-commits] branch master updated. 1863fbb132e3211b082e9bdd69734f83cdeaaa65

Mark Wells mark at 420.am
Wed Apr 27 15:07:02 PDT 2016


The branch, master has been updated
       via  1863fbb132e3211b082e9bdd69734f83cdeaaa65 (commit)
       via  14c989e0aea38668f27dc0492f8e6749bf0cd98c (commit)
       via  a057e75a089baf5c36c3523b5014ada747a925a6 (commit)
      from  2b2e19ae4838d1d788b244ceff85957c52b0655f (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 1863fbb132e3211b082e9bdd69734f83cdeaaa65
Author: Mark Wells <mark at freeside.biz>
Date:   Wed Apr 27 13:39:39 2016 -0700

    add Map::Splat to deps, #37802

diff --git a/debian/control b/debian/control
index 8924721..24ddea3 100644
--- a/debian/control
+++ b/debian/control
@@ -96,7 +96,8 @@ Depends: aspell-en,gnupg,ghostscript,gsfonts,gzip,latex-xcolor,
  libdata-guid-perl, libparams-classify-perl (>= 0.013-5.1),
  libcpanel-json-xs-perl, libarchive-zip-perl,
  libtry-tiny-perl, libnumber-phone-perl, libxml-libxml-simple-perl,
- libxml-writer-perl, libio-socket-ssl-perl
+ libxml-writer-perl, libio-socket-ssl-perl,
+ libmap-splat-perl
 Conflicts: libparams-classify-perl (>= 0.013-6)
 Suggests: libbusiness-onlinepayment-perl
 Description: Libraries for Freeside billing and trouble ticketing

commit 14c989e0aea38668f27dc0492f8e6749bf0cd98c
Author: Mark Wells <mark at freeside.biz>
Date:   Wed Apr 27 13:35:38 2016 -0700

    fix DST in prorate test

diff --git a/FS/t/suite/02-bill_customer.t b/FS/t/suite/02-bill_customer.t
index e3f6406..3fa908e 100755
--- a/FS/t/suite/02-bill_customer.t
+++ b/FS/t/suite/02-bill_customer.t
@@ -23,9 +23,10 @@ ok($error eq '', "billed on $date") or diag($error);
 my $cust_bill = $return[0];
 isa_ok($cust_bill, 'FS::cust_bill');
 
-# Apr 1 - Mar 20 = 12 days
-# 12/31 * $30 = 11.61 recurring, + 20.00 setup
-ok( $cust_bill->charged == 31.61, 'prorated first month correctly' );
+# Apr 1 - Mar 20 = 12 days = 288 hours
+# Apr 1 - Mar 1  = 31 days - 1 hour (DST) = 743 hours
+# 288/743 * $30 = $11.63 recur + $20.00 setup
+ok( $cust_bill->charged == 31.63, 'prorated first month correctly' );
 
 # the package bill date should now be 2016-04-01
 my @lineitems = $cust_bill->cust_bill_pkg;

commit a057e75a089baf5c36c3523b5014ada747a925a6
Author: Mark Wells <mark at freeside.biz>
Date:   Wed Apr 27 13:35:00 2016 -0700

    fix redirect on error in test environment

diff --git a/httemplate/elements/create_uri_query b/httemplate/elements/create_uri_query
index 414d53b..ce6249e 100644
--- a/httemplate/elements/create_uri_query
+++ b/httemplate/elements/create_uri_query
@@ -18,7 +18,7 @@ my $query = $cgi->query_string;
 
 if ( length($query) > 1920 || $opt{secure} ) { #stupid IE 2083 URL limit
 
-  my $session = random_id(9);
+  my $session = int(rand(4294967296)); #XXX
   my $pref = new FS::access_user_pref({
     'usernum'    => $FS::CurrentUser::CurrentUser->usernum,
     'prefname'   => "redirect$session",

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

Summary of changes:
 FS/t/suite/02-bill_customer.t        |    7 ++++---
 debian/control                       |    3 ++-
 httemplate/elements/create_uri_query |    2 +-
 3 files changed, 7 insertions(+), 5 deletions(-)




More information about the freeside-commits mailing list