Fake Drivers

When the real thing isn’t available and you have some development to do these fake implementations of various drivers let you get on with your day.

The cinder.tests.unit.test_service.FakeManager Class

class FakeManager(host=None, db_driver=None, service_name=None, cluster=None)

Bases: cinder.manager.Manager

Fake manager for tests.

test_method()

The cinder.tests.unit.api.fakes Module

class Context

Bases: object

class FakeAuthDatabase

Bases: object

static auth_token_create(context, token)
static auth_token_destroy(context, token_id)
static auth_token_get(context, token_hash)
data = {}
class FakeRateLimiter(application)

Bases: object

class FakeRequestContext(*args, **kwargs)

Bases: cinder.context.RequestContext

class FakeRouter(ext_mgr=None)

Bases: oslo_service.wsgi.Router

class FakeToken(**kwargs)

Bases: object

id_count = 0
class HTTPRequest(environ, charset=None, unicode_errors=None, decode_param_names=None, **kw)

Bases: webob.request.Request

classmethod blank(*args, **kwargs)
class TestRouter(controller)

Bases: oslo_service.wsgi.Router

get_fake_uuid(token=0)
wsgi_app(inner_app_v2=None, fake_auth=True, fake_auth_context=None, use_no_auth=False, ext_mgr=None, inner_app_v3=None)

Table Of Contents

Previous topic

Scheduler

Next topic

Common and Misc Libraries

This Page