]> git.koha-community.org Git - koha.git/commit
Bug 27833: (follow-up) Add InvalidType exception
authorTomas Cohen Arazi <tomascohen@theke.io>
Thu, 4 Mar 2021 10:39:27 +0000 (07:39 -0300)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Fri, 9 Apr 2021 13:43:26 +0000 (15:43 +0200)
commit577a4054070338ff5a135dca9f033a28b7abf5f3
tree1ed10b9ae12871c93b4de6badfa5434134724fb7
parent35aefaa11c72f91d4d6d64d88389f3e33a91f4fc
Bug 27833: (follow-up) Add InvalidType exception

Working on bug 27857 showed we needed one more exception, for when the
passed attribute type is invalid.

This patch adds the Koha::Exceptions::Patron::Attribute::InvalidType
exception. It adds a format for stringifying it, and tests are added.
The previous exceptions tests lacked one case, so I add them on this
patch as well.

To test:
1. Apply this patch
2. Run:
   $ kshell
  k$ prove tt/Koha/Exceptions.t
=> SUCCESS: Tests pass!
3. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Koha/Exceptions/Patron/Attribute.pm
t/Koha/Exceptions.t