Merge "Fixing db properties for testing purposes"
This commit is contained in:
commit
445af82e21
@ -140,6 +140,8 @@ function configure_mistral {
|
|||||||
|
|
||||||
# Configure the database.
|
# Configure the database.
|
||||||
iniset $MISTRAL_CONF_FILE database connection `database_connection_url mistral`
|
iniset $MISTRAL_CONF_FILE database connection `database_connection_url mistral`
|
||||||
|
iniset $MISTRAL_CONF_FILE database max_overflow -1
|
||||||
|
iniset $MISTRAL_CONF_FILE database max_pool_size 1000
|
||||||
|
|
||||||
# Configure keystone auth url
|
# Configure keystone auth url
|
||||||
iniset $MISTRAL_CONF_FILE keystone_authtoken auth_uri "http://${KEYSTONE_AUTH_HOST}:5000/v3"
|
iniset $MISTRAL_CONF_FILE keystone_authtoken auth_uri "http://${KEYSTONE_AUTH_HOST}:5000/v3"
|
||||||
|
@ -189,8 +189,12 @@ class DbTestCase(BaseTest):
|
|||||||
and can be extended by child classes.
|
and can be extended by child classes.
|
||||||
"""
|
"""
|
||||||
cfg.CONF.set_default('connection', 'sqlite://', group='database')
|
cfg.CONF.set_default('connection', 'sqlite://', group='database')
|
||||||
|
cfg.CONF.set_default('max_overflow', -1, group='database')
|
||||||
|
cfg.CONF.set_default('max_pool_size', 1000, group='database')
|
||||||
|
|
||||||
db_api_v1.setup_db()
|
db_api_v1.setup_db()
|
||||||
db_api_v2.setup_db()
|
db_api_v2.setup_db()
|
||||||
|
|
||||||
action_manager.sync_db()
|
action_manager.sync_db()
|
||||||
|
|
||||||
def _clean_db(self):
|
def _clean_db(self):
|
||||||
@ -210,15 +214,15 @@ class DbTestCase(BaseTest):
|
|||||||
super(DbTestCase, self).setUp()
|
super(DbTestCase, self).setUp()
|
||||||
|
|
||||||
self.__heavy_init()
|
self.__heavy_init()
|
||||||
cfg.CONF.set_default('connection', 'sqlite://', group='database')
|
|
||||||
db_api_v1.setup_db()
|
|
||||||
db_api_v2.setup_db()
|
|
||||||
|
|
||||||
self.ctx = auth_context.MistralContext(user_id='1-2-3-4',
|
self.ctx = auth_context.MistralContext(
|
||||||
project_id='5-6-7-8',
|
user_id='1-2-3-4',
|
||||||
user_name='test-user',
|
project_id='5-6-7-8',
|
||||||
project_name='test-project',
|
user_name='test-user',
|
||||||
is_admin=False)
|
project_name='test-project',
|
||||||
|
is_admin=False
|
||||||
|
)
|
||||||
|
|
||||||
auth_context.set_ctx(self.ctx)
|
auth_context.set_ctx(self.ctx)
|
||||||
|
|
||||||
self.addCleanup(auth_context.set_ctx, None)
|
self.addCleanup(auth_context.set_ctx, None)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user