Преглед изворни кода

[3.1] Removed use of dict comprehension

Ask Solem пре 9 година
родитељ
комит
539e986a05
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      celery/tests/utils/test_functional.py

+ 1 - 1
celery/tests/utils/test_functional.py

@@ -64,7 +64,7 @@ class test_LRUCache(Case):
 
     def test_update_larger_than_cache_size(self):
         x = LRUCache(2)
-        x.update({x: x for x in range(100)})
+        x.update(dict((x, x) for x in range(100)))
         self.assertEqual(list(x.keys()), [98, 99])
 
     def assertSafeIter(self, method, interval=0.01, size=10000):