Created attachment 57297 [details] [review] Bug 17579: Add the Koha::Patron->is_expired This new method will be handy for further uses Test plan: prove t/db_dependent/Koha/Patrons.t should return green
Created attachment 57320 [details] [review] [SIGNED-OFF] Bug 17579: Add the Koha::Patron->is_expired This new method will be handy for further uses Test plan: prove t/db_dependent/Koha/Patrons.t should return green Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 57332 [details] [review] Bug 17579: Add the Koha::Patron->is_expired This new method will be handy for further uses Test plan: prove t/db_dependent/Koha/Patrons.t should return green Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 57386 [details] [review] Bug 17579: Make sure we are testing the real life Without this patch, the tests are not testing the same things as what happens on the interface. We need to refresh the object to make sure the date set into dateexpiry is the one in DB. Without this patch, ->is_expired test a datetime object, with this patch it compares with a date oject Without the changes made in Koha::Patron->is_expired, a patron which has a dateexpiry set to today was marked as expired on the interface. This is a change in the behavior, what this refactoring does not want to do.
Created attachment 57411 [details] [review] Bug 17579: Add the Koha::Patron->is_expired This new method will be handy for further uses Test plan: prove t/db_dependent/Koha/Patrons.t should return green Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 57412 [details] [review] Bug 17579: Make sure we are testing the real life Without this patch, the tests are not testing the same things as what happens on the interface. We need to refresh the object to make sure the date set into dateexpiry is the one in DB. Without this patch, ->is_expired test a datetime object, with this patch it compares with a date oject Without the changes made in Koha::Patron->is_expired, a patron which has a dateexpiry set to today was marked as expired on the interface. This is a change in the behavior, what this refactoring does not want to do.
I have removed the dependency on bug 17580 to make these patches reusable by other patches.
Created attachment 57475 [details] [review] [SIGNED-OFF] Bug 17579: Add the Koha::Patron->is_expired This new method will be handy for further uses Test plan: prove t/db_dependent/Koha/Patrons.t should return green Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 57476 [details] [review] [SIGNED-OFF] Bug 17579: Make sure we are testing the real life Without this patch, the tests are not testing the same things as what happens on the interface. We need to refresh the object to make sure the date set into dateexpiry is the one in DB. Without this patch, ->is_expired test a datetime object, with this patch it compares with a date oject Without the changes made in Koha::Patron->is_expired, a patron which has a dateexpiry set to today was marked as expired on the interface. This is a change in the behavior, what this refactoring does not want to do. Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 57498 [details] [review] Bug 17579: Add the Koha::Patron->is_expired This new method will be handy for further uses Test plan: prove t/db_dependent/Koha/Patrons.t should return green Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 57499 [details] [review] Bug 17579: Make sure we are testing the real life Without this patch, the tests are not testing the same things as what happens on the interface. We need to refresh the object to make sure the date set into dateexpiry is the one in DB. Without this patch, ->is_expired test a datetime object, with this patch it compares with a date oject Without the changes made in Koha::Patron->is_expired, a patron which has a dateexpiry set to today was marked as expired on the interface. This is a change in the behavior, what this refactoring does not want to do. Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 57500 [details] [review] Bug 17579 [QA Followup] - Fix the number of tests Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Pushed to master for 16.11, thanks Jonathan!