Add initial mock cloud provider class
This commit is contained in:
parent
2dba02e03c
commit
3dad43b1ee
@ -1,9 +1,11 @@
|
||||
from .cloud import MockCloudProvider
|
||||
from .files import RackspaceFileProvider
|
||||
from .reports import MockReportingProvider
|
||||
|
||||
|
||||
class MockCSP:
|
||||
def __init__(self, app):
|
||||
self.cloud = MockCloudProvider()
|
||||
self.files = RackspaceFileProvider(app)
|
||||
self.reports = MockReportingProvider()
|
||||
|
||||
|
16
atst/domain/csp/cloud.py
Normal file
16
atst/domain/csp/cloud.py
Normal file
@ -0,0 +1,16 @@
|
||||
from uuid import uuid4
|
||||
|
||||
|
||||
class CloudProviderInterface:
|
||||
def create_application(self, name): # pragma: no cover
|
||||
"""Create an application in the cloud with the provided name. Returns
|
||||
the ID of the created object.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
|
||||
|
||||
class MockCloudProvider(CloudProviderInterface):
|
||||
def create_application(self, name):
|
||||
"""Returns an id that represents what would be an application in the
|
||||
cloud."""
|
||||
return uuid4().hex
|
Loading…
x
Reference in New Issue
Block a user