cleanup the no_sqlite_wrap attribute after this test is executed stable
authorAlexandre Fayolle <alexandre.fayolle@logilab.fr>
Thu, 03 Jun 2010 09:24:41 +0200
branchstable
changeset 5648 d6bee21cf5db
parent 5647 b21655cfc835
child 5649 a07dee204187
cleanup the no_sqlite_wrap attribute after this test is executed
server/test/unittest_multisources.py
--- a/server/test/unittest_multisources.py	Wed Jun 02 23:06:38 2010 +0200
+++ b/server/test/unittest_multisources.py	Thu Jun 03 09:24:41 2010 +0200
@@ -24,7 +24,6 @@
 from cubicweb.devtools.testlib import CubicWebTC, refresh_repo
 from cubicweb.devtools.repotest import do_monkey_patch, undo_monkey_patch
 
-TestServerConfiguration.no_sqlite_wrap = True
 
 class TwoSourcesConfiguration(TestServerConfiguration):
     sourcefile = 'sources_multi'
@@ -48,6 +47,7 @@
 Connection_close = Connection.close
 
 def setup_module(*args):
+    TestServerConfiguration.no_sqlite_wrap = True
     # hi-jack PyroRQLSource.get_connection to access existing connection (no
     # pyro connection)
     PyroRQLSource.get_connection = lambda x: x.uri == 'extern-multi' and cnx3 or cnx2
@@ -64,6 +64,7 @@
     del repo2, cnx2, repo3, cnx3
     #del TwoSourcesTC.config.vreg
     #del TwoSourcesTC.config
+    TestServerConfiguration.no_sqlite_wrap = False
 
 class TwoSourcesTC(CubicWebTC):
     config = TwoSourcesConfiguration('data')