cubicweb/test/unittest_entity.py
changeset 11764 6ab14a1afb65
parent 11762 7518cb58ab4c
child 11767 432f87a63057
--- a/cubicweb/test/unittest_entity.py	Fri Sep 30 17:39:17 2016 +0200
+++ b/cubicweb/test/unittest_entity.py	Thu Oct 06 12:15:50 2016 +0200
@@ -832,10 +832,14 @@
             self.assertEqual(len(person.reverse_ecrit_par), 2)
 
     def test_metainformation(self):
-        with self.admin_access.web_request() as req:
-            note = req.create_entity('Note', type=u'z')
+        with self.admin_access.client_cnx() as cnx:
+            note = cnx.create_entity('Note', type=u'z')
+            cnx.commit()
+            note.cw_clear_all_caches()
             metainf = note.cw_metainformation()
-            self.assertEqual(metainf, {'type': u'Note', 'extid': None})
+            self.assertEqual(metainf, {'type': u'Note',
+                                       'extid': None,
+                                       'source': {'uri': 'system'}})
 
     def test_absolute_url_empty_field(self):
         with self.admin_access.web_request() as req: