[Review] Request from 'wstephenson' @ 'SUSE/connect/review_140908_error_on_stale_credentials_2156'

Please review the following changes:
  * d22be46 Useful error message on 401
  * 4fc8eba Integration test
I would recommend to use case/when with code in the when clause