[test] make unittest_schemaserial.py runnable with python stable
authorDavid Douard <david.douard@logilab.fr>
Fri, 05 Jul 2013 10:35:14 +0200
branchstable
changeset 9140 e7ffe39d4b1a
parent 9139 5ca6e0ab0227
child 9141 492216093bc3
[test] make unittest_schemaserial.py runnable with python used to run fine only when launched using pytest
server/test/unittest_schemaserial.py
--- a/server/test/unittest_schemaserial.py	Mon Jul 08 17:38:10 2013 +0200
+++ b/server/test/unittest_schemaserial.py	Fri Jul 05 10:35:14 2013 +0200
@@ -28,6 +28,7 @@
 from logilab.database import get_db_helper
 from yams import register_base_type, unregister_base_type
 
+schema = config = None
 def setUpModule(*args):
     register_base_type('BabarTestType', ('jungle_speed',))
     helper = get_db_helper('sqlite')
@@ -44,7 +45,7 @@
 
 def tearDownModule(*args):
     global schema, config
-    del schema, config
+    schema = config = None
 
     unregister_base_type('BabarTestType')
     helper = get_db_helper('sqlite')