2015-09-30 9:20 GMT-03:00 Philippe Blouin <philippe.blouin@inlibro.com>:Because the code would be extremely specific to a specific functionality, whereas the code in the libraries is there to be reused.
And let not go overboard with OO.We embrace the OO paradigm for most of the CRUD operations, but we also have libs containing functions that are used statically, like Koha::Util::MARC, that do specific things and are testable. And is only used in a couple places.A script is a script is a script. Make it readable, add functions to make it cleaner, make your functions readable.We have two main kind of scripts: command line scripts, and controller scripts that got too complicated during Koha's life, and we are trying to simplify "as we go".I think both should be testable.