[test] fixes
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Fri, 08 Oct 2010 11:11:31 +0200
changeset 6417 d2361abe8505
parent 6416 2ca48e45522e
child 6418 948a9f8514b2
[test] fixes
server/test/unittest_migractions.py
web/test/unittest_facet.py
--- a/server/test/unittest_migractions.py	Fri Oct 08 11:11:09 2010 +0200
+++ b/server/test/unittest_migractions.py	Fri Oct 08 11:11:31 2010 +0200
@@ -141,6 +141,7 @@
             self.assertRaises(ValidationError,
                               self.mh.rqlexec,
                               'INSERT Note N: N unique_id "xyz"')
+            self.mh.rollback()
             # make sure the unique constraint is dropped
             self.mh.rqlexec('INSERT Note N: N unique_id "x"')
             self.mh.rqlexec('INSERT Note N: N unique_id "x"')
--- a/web/test/unittest_facet.py	Fri Oct 08 11:11:09 2010 +0200
+++ b/web/test/unittest_facet.py	Fri Oct 08 11:11:31 2010 +0200
@@ -87,9 +87,9 @@
                           [str(guests), str(managers)])
         f._cw.create_entity('CWUser', login=u'hop', upassword='toto')
         self.assertEqual(f.vocabulary(),
-                          [(u'no relation', ''), (u'guests', guests), (u'managers', managers)])
+                          [(u'<no relation>', ''), (u'guests', guests), (u'managers', managers)])
         self.assertEqual(f.possible_values(),
-                          [str(guests), str(managers)])
+                          [str(guests), str(managers), ''])
         f._cw.form[f.__regid__] = ''
         f.add_rql_restrictions()
         self.assertEqual(f.rqlst.as_string(),