Bug 1547730 - Fix b''.join(rand.choice(bytestring)..) to use bytes() constructor instead r=#build
☠☠ backed out by ee4b88439111 ☠ ☠
authorJustin Wood <Callek@gmail.com>
Mon, 15 Apr 2019 15:26:30 -0400
changeset 474147 3037f5bf1019d1eb730e31857e1a8d4d4216eadb
parent 474146 3df74540bde34a0514c2b98bab05152d2b1cffed
child 474148 6c9f98dacbde5f8bd5a810e17ca3013812e814f2
push id36023
push userncsoregi@mozilla.com
push dateThu, 16 May 2019 21:56:43 +0000
treeherdermozilla-central@786f094a30ae [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1547730
milestone68.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1547730 - Fix b''.join(rand.choice(bytestring)..) to use bytes() constructor instead r=#build Differential Revision: https://phabricator.services.mozilla.com/D28107
python/mozbuild/mozpack/test/test_files.py
--- a/python/mozbuild/mozpack/test/test_files.py
+++ b/python/mozbuild/mozpack/test/test_files.py
@@ -158,19 +158,18 @@ class TestDest(TestWithTmpDir):
         dest.close()
         self.assertEqual(dest.read(), 'bar')
         dest.write('foo')
         dest.close()
         dest.write('qux')
         self.assertEqual(dest.read(), 'qux')
 
 
-rand = b''.join(random.choice(
-    b'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ')
-                for i in six.moves.xrange(131597))
+rand = bytes(random.choice(b'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ')
+             for i in six.moves.xrange(131597))
 samples = [
     b'',
     b'test',
     b'fooo',
     b'same',
     b'same',
     b'Different and longer',
     rand,