server/migractions.py
changeset 6574 a7bbd69f1d1c
parent 6427 c8a5ac2d1eaa
parent 6571 71b446d1cf93
child 6582 8eb7883b4223
--- a/server/migractions.py	Thu Oct 21 09:48:38 2010 +0200
+++ b/server/migractions.py	Thu Oct 21 09:49:27 2010 +0200
@@ -45,7 +45,6 @@
 
 from logilab.common.deprecation import deprecated
 from logilab.common.decorators import cached, clear_cache
-from logilab.common.testlib import mock_object
 
 from yams.constraints import SizeConstraint
 from yams.schema2sql import eschema2sql, rschema2sql
@@ -68,6 +67,10 @@
 except ImportError: # LAX
     pass
 
+
+def mock_object(**params):
+    return type('Mock', (), params)()
+
 class ClearGroupMap(hook.Hook):
     __regid__ = 'cw.migration.clear_group_mapping'
     __select__ = hook.Hook.__select__ & is_instance('CWGroup')