[test] Avoid ambiguous variable name "l" in unittest_req.py
authorDenis Laxalde <denis.laxalde@logilab.fr>
Mon, 30 Oct 2017 09:18:20 +0100
changeset 12218 d3f3c4a4edd9
parent 12209 3a3551fff787
child 12219 4b5f1b676366
[test] Avoid ambiguous variable name "l" in unittest_req.py This is an error (E741) from flake8 3.5.
cubicweb/test/unittest_req.py
--- a/cubicweb/test/unittest_req.py	Fri Sep 15 14:14:46 2017 +0200
+++ b/cubicweb/test/unittest_req.py	Mon Oct 30 09:18:20 2017 +0100
@@ -110,15 +110,15 @@
                 firstname=u'adrien',
                 in_group=req.find('CWGroup', name=u'users').one())
 
-            l = list(req.find_entities('CWUser', login=u'cdevienne'))
-            self.assertEqual(1, len(l))
-            self.assertEqual(l[0].firstname, u"Christophe")
+            users = list(req.find_entities('CWUser', login=u'cdevienne'))
+            self.assertEqual(1, len(users))
+            self.assertEqual(users[0].firstname, u"Christophe")
 
-            l = list(req.find_entities('CWUser', login=u'patanok'))
-            self.assertEqual(0, len(l))
+            users = list(req.find_entities('CWUser', login=u'patanok'))
+            self.assertEqual(0, len(users))
 
-            l = list(req.find_entities('CWUser'))
-            self.assertEqual(4, len(l))
+            users = list(req.find_entities('CWUser'))
+            self.assertEqual(4, len(users))
 
     def test_find(self):
         with self.admin_access.web_request() as req: