Permalink
Browse files

Made main user disconnect after creating test user/tablespaces on Oracle

  • Loading branch information...
1 parent e0cf030 commit 4c85a0d95fa39f33c0f5335199a2e9d58a8736a9 @shaib shaib committed Aug 25, 2014
Showing with 2 additions and 0 deletions.
  1. +2 −0 django/db/backends/oracle/creation.py
View
2 django/db/backends/oracle/creation.py
@@ -120,6 +120,8 @@ def _create_test_db(self, verbosity=1, autoclobber=False, keepdb=False):
print("Tests cancelled.")
sys.exit(1)
+ self.connection.close() # done with main user -- test user and tablespaces created
+
real_settings = settings.DATABASES[self.connection.alias]
real_settings['SAVED_USER'] = self.connection.settings_dict['SAVED_USER'] = self.connection.settings_dict['USER']
real_settings['SAVED_PASSWORD'] = self.connection.settings_dict['SAVED_PASSWORD'] = self.connection.settings_dict['PASSWORD']

0 comments on commit 4c85a0d

Please sign in to comment.