While it might have seemed a good idea to have such a test, I find it useless as-is, because there's no obvious reason why we would expose our model on the API spec while it is just user-facing and not a technical explanation on how we do things inside our codebase. A good example of this could be bug 18120, in which it is obvious that some attribute names are misleading or the attributes themselves need to be stripped out of the object for exposing on the API. There can be ways of doing this two operations (i.e. removing/adding attributes, and renaming) without handling it on the controller as those patches do. But in any case, there's no need for definitions.t. We could have a gentle 'warning' in the QA tools in case of a column being added to the DB structure and not to the corresponding endpoint, but it has to be a soft requirement IMO.
Created attachment 67241 [details] [review] Bug 19119: Remove definitions.t This patch removes t/db_dependent/api/v1/swagger/definitions.t Its goal is not simple to achieve, and worth moving into the QA tools instead. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 67267 [details] [review] Bug 19119: Remove definitions.t This patch removes t/db_dependent/api/v1/swagger/definitions.t Its goal is not simple to achieve, and worth moving into the QA tools instead. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Let remove it and see later if we need something else.
Pushed to master for 17.11, thanks to everybody involved!
Enhancement not pushed to 17.05.x