D5757: tests: use items() in test-remotefilelog-datapack.py
indygreg (Gregory Szorc)
phabricator at mercurial-scm.org
Wed Jan 30 21:37:41 UTC 2019
indygreg created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
Performance doesn't matter in tests. iteritems() doesn't exist
in Python 3.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5757
AFFECTED FILES
tests/test-remotefilelog-datapack.py
CHANGE DETAILS
diff --git a/tests/test-remotefilelog-datapack.py b/tests/test-remotefilelog-datapack.py
--- a/tests/test-remotefilelog-datapack.py
+++ b/tests/test-remotefilelog-datapack.py
@@ -158,7 +158,7 @@
pack = self.createPack(revisions)
# Verify the pack contents
- for (filename, node, lastnode), content in sorted(blobs.iteritems()):
+ for (filename, node, lastnode), content in sorted(blobs.items()):
chain = pack.getdeltachain(filename, node)
for entry in chain:
expectedcontent = blobs[(entry[0], entry[1], entry[3])]
@@ -258,7 +258,7 @@
self.assertEqual(pack.params.fanoutprefix,
basepack.LARGEFANOUTPREFIX)
- for (filename, node), content in blobs.iteritems():
+ for (filename, node), content in blobs.items():
actualcontent = pack.getdeltachain(filename, node)[0][4]
self.assertEqual(actualcontent, content)
To: indygreg, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list