--- a/server/test/unittest_querier.py Tue Apr 10 16:59:27 2012 +0200
+++ b/server/test/unittest_querier.py Tue Apr 10 16:59:50 2012 +0200
@@ -1502,10 +1502,12 @@
self.assertFalse(self.execute('Any X WHERE X is CWEType, X name %(name)s', {'name': None}))
self.assertTrue(self.execute('Any X WHERE X is CWEType, X name %(name)s', {'name': 'CWEType'}))
+
class NonRegressionTC(CubicWebTC):
+
def test_has_text_security_cache_bug(self):
- self.create_user('user', ('users',))
req = self.request()
+ self.create_user(req, 'user', ('users',))
aff1 = req.create_entity('Societe', nom=u'aff1')
aff2 = req.create_entity('Societe', nom=u'aff2')
self.commit()
@@ -1514,5 +1516,6 @@
self.assertEqual(res.rows, [[aff1.eid]])
res = self.execute('Any X WHERE X has_text %(text)s', {'text': 'aff2'})
self.assertEqual(res.rows, [[aff2.eid]])
+
if __name__ == '__main__':
unittest_main()