Given a patron attempt the ValidatePatronTransition attempts to validatePatronIdentity and fetch a host patron
When hostLmsPatron.getIsDeleted() != null && hostLmsPatron.getIsDeleted()
Then throwPatronDeletedInHostLmsException :
Code Block PatronDeletedInHostLmsException( "Patron with local id " + hostLmsPatron.getLocalId() + " and home library code " + hostLmsPatron.getLocalHomeLibraryCode() + " had a deleted flag.")
Given a patron attempt the ValidatePatronTransition attempts to resolveHomeLibraryCodeFromSystemToAgencyCode
When systemCode == null
Then throwRuntimeException :
Code Block RuntimeException("Missing system code. Unable to accept request")
Given a patron attempt the ValidatePatronTransition attempts to resolveHomeLibraryCodeFromSystemToAgencyCode
When return chain completes with empty
Then throw
NoAgencyFoundException
:Code Block NoAgencyFoundException( "Unable to resolve patron home library code(" + systemCode + "/" + homeLibraryCode + ") to an agency")
Given a patron attempt the ValidatePatronTransition attempts to findOneAgencyByCode
When return chain completes with empty
Then throw
NoAgencyFoundException
:Code Block NoAgencyFoundException("No agency found with code: " + code)
...