Bugzilla – Attachment 156221 Details for
Bug 34912
Account(s).t tests fail in UTC+1 and higher
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34912: Add 14 hours to 1970 date in Account(s).t
Bug-34912-Add-14-hours-to-1970-date-in-Accountst.patch (text/plain), 4.49 KB, created by
Marcel de Rooy
on 2023-09-26 11:51:23 UTC
(
hide
)
Description:
Bug 34912: Add 14 hours to 1970 date in Account(s).t
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2023-09-26 11:51:23 UTC
Size:
4.49 KB
patch
obsolete
>From 3b56440cce4faa289b7008e92b88b86f44ca51ab Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Wed, 27 Sep 2023 01:45:58 +1400 >Subject: [PATCH] Bug 34912: Add 14 hours to 1970 date in Account(s).t >Content-Type: text/plain; charset=utf-8 > >This makes those tests pass in whatever timezone. > >Test plan: >Do not yet apply patch. >Change timezone on commandline with: export TZ='Etc/GMT-14' >NOTE: GMT-14 is what we also call UTC+14 (sign reversed). >Run prove t/db_dependent/Accounts.t t/db_dependent/Koha/Account.t >This fails now. >Apply patch. >Rerun tests and verify that they pass now. >Bonus: Try some other time zone. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > t/db_dependent/Accounts.t | 12 ++++++------ > t/db_dependent/Koha/Account.t | 4 ++-- > 2 files changed, 8 insertions(+), 8 deletions(-) > >diff --git a/t/db_dependent/Accounts.t b/t/db_dependent/Accounts.t >index df53e0704b..f749706a6c 100755 >--- a/t/db_dependent/Accounts.t >+++ b/t/db_dependent/Accounts.t >@@ -866,7 +866,7 @@ subtest "Koha::Account::non_issues_charges tests" => sub { > my $debit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amountoutstanding => 0, > interface => 'commandline', > debit_type_code => 'LOST' >@@ -875,7 +875,7 @@ subtest "Koha::Account::non_issues_charges tests" => sub { > my $credit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amountoutstanding => -5, > interface => 'commandline', > credit_type_code => 'PAYMENT' >@@ -899,7 +899,7 @@ subtest "Koha::Account::non_issues_charges tests" => sub { > $debit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amountoutstanding => 5, > interface => 'commanline', > debit_type_code => 'LOST' >@@ -908,7 +908,7 @@ subtest "Koha::Account::non_issues_charges tests" => sub { > $credit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amountoutstanding => 0, > interface => 'commandline', > credit_type_code => 'PAYMENT' >@@ -933,7 +933,7 @@ subtest "Koha::Account::non_issues_charges tests" => sub { > $debit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amountoutstanding => 0, > interface => 'commandline', > debit_type_code => 'LOST' >@@ -942,7 +942,7 @@ subtest "Koha::Account::non_issues_charges tests" => sub { > $credit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amountoutstanding => 0, > interface => 'commandline', > credit_type_code => 'PAYMENT' >diff --git a/t/db_dependent/Koha/Account.t b/t/db_dependent/Koha/Account.t >index 57ecd741aa..39a84a7eb2 100755 >--- a/t/db_dependent/Koha/Account.t >+++ b/t/db_dependent/Koha/Account.t >@@ -1153,7 +1153,7 @@ subtest 'Koha::Account::Line::apply() handles lost items' => sub { > my $credit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amount => -.5, > amountoutstanding => -.5, > interface => 'commandline', >@@ -1172,7 +1172,7 @@ subtest 'Koha::Account::Line::apply() handles lost items' => sub { > $credit = Koha::Account::Line->new( > { > borrowernumber => $patron->id, >- date => '1970-01-01 00:00:01', >+ date => '1970-01-01 14:00:01', > amount => -.5, > amountoutstanding => -.5, > interface => 'commandline', >-- >2.30.2
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 34912
:
156221
|
156380