Large parts of the logic from overdue_notice.pl can and should be moved into a module. This would a) Allow for unit tests b) Allow the code to be shared with other parts of Koha c) De-couple the notice generation and patron debarment functions of overdue_notice.pl d) Fix Bug 2389 - overdue_notices.pl needs a test mode