[test] add some tags stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Thu, 10 Mar 2011 15:18:22 +0100
branchstable
changeset 7073 4ce9e536dd66
parent 7072 bcf96f2a4c5d
child 7074 e4580e5f0703
child 7075 4751d77394b1
[test] add some tags
server/test/unittest_migractions.py
--- a/server/test/unittest_migractions.py	Thu Mar 10 15:18:21 2011 +0100
+++ b/server/test/unittest_migractions.py	Thu Mar 10 15:18:22 2011 +0100
@@ -23,7 +23,7 @@
 from datetime import date
 from os.path import join
 
-from logilab.common.testlib import TestCase, unittest_main
+from logilab.common.testlib import TestCase, unittest_main, Tags, tag
 
 from yams.constraints import UniqueConstraint
 
@@ -37,10 +37,13 @@
 def tearDownModule(*args):
     global migrschema
     del migrschema
-    del MigrationCommandsTC.origschema
+    if hasattr(MigrationCommandsTC, 'origschema'):
+        del MigrationCommandsTC.origschema
 
 class MigrationCommandsTC(CubicWebTC):
 
+    tags = CubicWebTC.tags | Tags(('server', 'migration', 'migractions'))
+
     @classmethod
     def init_config(cls, config):
         super(MigrationCommandsTC, cls).init_config(config)
@@ -343,6 +346,7 @@
             self.mh.cmd_change_relation_props('Personne', 'adel', 'String',
                                               fulltextindexed=False)
 
+    @tag('longrun')
     def test_sync_schema_props_perms(self):
         cursor = self.mh.session
         cursor.set_pool()
@@ -464,6 +468,7 @@
         finally:
             self.mh.cmd_set_size_constraint('CWEType', 'description', None)
 
+    @tag('longrun')
     def test_add_remove_cube_and_deps(self):
         cubes = set(self.config.cubes())
         schema = self.repo.schema
@@ -527,6 +532,7 @@
             self.commit()
 
 
+    @tag('longrun')
     def test_add_remove_cube_no_deps(self):
         cubes = set(self.config.cubes())
         schema = self.repo.schema
@@ -558,6 +564,7 @@
             self.mh.cmd_remove_cube('file')
         self.assertEqual(str(cm.exception), "can't remove cube file, used as a dependency")
 
+    @tag('longrun')
     def test_introduce_base_class(self):
         self.mh.cmd_add_entity_type('Para')
         self.mh.repo.schema.rebuild_infered_relations()