Bug 22254: Correction to datehandling in test
authorMartin Renvoize <martin.renvoize@ptfs-europe.com>
Fri, 1 Feb 2019 09:55:54 +0000 (09:55 +0000)
committerNick Clemens <nick@bywatersolutions.com>
Mon, 4 Feb 2019 14:43:01 +0000 (14:43 +0000)
commit1da0ba48b6fdf38cfd3d3ea63ec076b15995610f
tree0eb24355e4631cee4dbc29d60f7f1a5fdd246d61
parenta32653a66fa02f1fe9002647d337261bf36d62e0
Bug 22254: Correction to datehandling in test

Adding 13 months is not always the same as adding 1 month and then
adding 12 months in DateTime maths.  This patch rectified the test
to match the correct behaviour in koha.

Test plan.

1) Modify the test (around line 268) to test against the suspect
   leap date of 2019-01-31 and watch the test fail.
2) Apply the patch (which also adds this modification to test
   for such a leap date) and watch the test now pass.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
t/db_dependent/Koha/Patrons.t