Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_401(self):
self.queue(401)
self.check(smartcar.AuthenticationException)
def test_oauth_error(self):
self.queue(401, error_description='unauthorized')
try:
smartcar.requester.call('GET', self.URL)
except smartcar.AuthenticationException as err:
self.assertEqual(err.message, 'unauthorized')