nuropb.testing.stubs
Module Contents
Classes
Functions
This is a stub for the authorize_func that is used in the tests |
Data
API
- nuropb.testing.stubs.logger
None
- nuropb.testing.stubs.IN_GITHUB_ACTIONS
None
- nuropb.testing.stubs.get_claims_from_token(bearer_token: str) Dict[str, Any] | None
This is a stub for the authorize_func that is used in the tests
- class nuropb.testing.stubs.ServiceStub(service_name: str, instance_id: Optional[str] = None, private_key: Optional[cryptography.hazmat.primitives.asymmetric.rsa.RSAPrivateKey] = None)
Initialization
- _service_name: str
None
- _instance_id: str
None
- _private_key: cryptography.hazmat.primitives.asymmetric.rsa.RSAPrivateKey
None
- property service_name: str
- property instance_id: str
- property private_key: cryptography.hazmat.primitives.asymmetric.rsa.RSAPrivateKey
- class nuropb.testing.stubs.ServiceExample(*args: Any, **kwargs: Any)
Bases:
nuropb.testing.stubs.ServiceStubInitialization
- _method_call_count: int
None
- _raise_call_again_error: bool
None
- test_method(**kwargs: Any) str
- async do_async_task(**kwargs: Any) str
- async test_async_method(**kwargs: Any) str
- test_success_error(**kwargs: Any) None
- test_requires_user_claims(ctx: nuropb.contexts.context_manager.NuropbContextManager, **kwargs: Any) Any
- test_requires_encryption(ctx: nuropb.contexts.context_manager.NuropbContextManager, **kwargs: Any) Any
- test_call_again_error(**kwargs: Any) Dict[str, Any]
- test_call_again_loop(**kwargs: Any) None