Skip to content

Commit

Permalink
wrap map calls in list calls
Browse files Browse the repository at this point in the history
  • Loading branch information
andbag committed Apr 17, 2019
1 parent 1dc26e1 commit 3b8914d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Products/ZCatalog/tests/test_cache.py
Expand Up @@ -106,8 +106,8 @@ def _apply_query(self, query):
self.assertEqual(stats[0]['misses'], misses)

# compare result
rset1 = map(lambda x: x.getRID(), res1)
rset2 = map(lambda x: x.getRID(), res2)
rset1 = list(map(lambda x: x.getRID(), res1))
rset2 = list(map(lambda x: x.getRID(), res2))
self.assertEqual(rset1, rset2)

def _get_cache_key(self, query=None):
Expand Down Expand Up @@ -176,6 +176,6 @@ def test_cache_invalidate(self):
self.assertEqual(stats[0]['misses'], misses + 1)

# compare result
rset1 = map(lambda x: x.getRID(), res1)
rset2 = map(lambda x: x.getRID(), res2)
rset1 = list(map(lambda x: x.getRID(), res1))
rset2 = list(map(lambda x: x.getRID(), res2))
self.assertEqual(rset1, rset2)

0 comments on commit 3b8914d

Please sign in to comment.