зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1547730 - Use six.moves.xrange() instead of xrange() r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D28106 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
ed83d2e2f0
Коммит
043346856b
|
@ -397,7 +397,7 @@ class JarReader(object):
|
|||
preload = JarStruct.get_data('uint32', self._data)[0]
|
||||
entries = OrderedDict()
|
||||
offset = self._cdir_end['cdir_offset']
|
||||
for e in xrange(self._cdir_end['cdir_entries']):
|
||||
for e in six.moves.xrange(self._cdir_end['cdir_entries']):
|
||||
entry = JarCdirEntry(self._data[offset:])
|
||||
offset += entry.size
|
||||
# Creator host system. 0 is MSDOS, 3 is Unix
|
||||
|
|
|
@ -165,7 +165,7 @@ class TestDest(TestWithTmpDir):
|
|||
|
||||
rand = b''.join(random.choice(
|
||||
b'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ')
|
||||
for i in xrange(131597))
|
||||
for i in six.moves.xrange(131597))
|
||||
samples = [
|
||||
b'',
|
||||
b'test',
|
||||
|
@ -715,7 +715,7 @@ class TestDeflatedFile(TestWithTmpDir):
|
|||
for content in samples:
|
||||
name = b''.join(random.choice(
|
||||
b'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ')
|
||||
for i in xrange(8))
|
||||
for i in range(8))
|
||||
jar.add(name, content, compress=True)
|
||||
contents[name] = content
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче