##// END OF EJS Templates
db: Change ordering of test env setup and db connection init....
johbo -
r117:25511505 default
parent child Browse files
Show More
@@ -165,14 +165,15 b' def make_pyramid_app(global_config, **se'
165 config = Configurator(settings=settings)
165 config = Configurator(settings=settings)
166 add_pylons_compat_data(config.registry, global_config, settings_pylons)
166 add_pylons_compat_data(config.registry, global_config, settings_pylons)
167
167
168 # If this is a test run we prepare the test environment like
169 # creating a test database, test search index and test repositories.
170 # This has to be done before the database connection is initialized.
171 if settings['is_test']:
172 utils.initialize_test_environment(settings_merged)
173
168 # Initialize the database connection.
174 # Initialize the database connection.
169 utils.initialize_database(settings_merged)
175 utils.initialize_database(settings_merged)
170
176
171 # If this is a test run we prepare the test environment like
172 # creating a test database, test search index and test repositories.
173 if settings['is_test']:
174 utils.initialize_test_environment(settings_merged)
175
176 includeme(config)
177 includeme(config)
177 includeme_last(config)
178 includeme_last(config)
178 pyramid_app = config.make_wsgi_app()
179 pyramid_app = config.make_wsgi_app()
General Comments 0
You need to be logged in to leave comments. Login now