def oauth_validator(self, pyramid_config, pyramid_request):
     svc = mock.Mock(
         spec=oauth_validator_service_factory(None, pyramid_request))
     pyramid_config.register_service(svc, name='oauth_validator')
     return svc
Esempio n. 2
0
 def test_provides_user_service(self, pyramid_request, user_svc):
     svc = oauth_validator_service_factory(None, pyramid_request)
     assert svc.user_svc == user_svc
Esempio n. 3
0
 def test_provides_user_service(self, pyramid_request, user_svc):
     svc = oauth_validator_service_factory(None, pyramid_request)
     assert svc.user_svc == user_svc
Esempio n. 4
0
 def test_it_returns_oauth_service(self, pyramid_request):
     svc = oauth_validator_service_factory(None, pyramid_request)
     assert isinstance(svc, OAuthValidatorService)
Esempio n. 5
0
 def test_it_returns_oauth_service(self, pyramid_request):
     svc = oauth_validator_service_factory(None, pyramid_request)
     assert isinstance(svc, OAuthValidatorService)