Patchwork D3505: tests: port test-cbor.py to Python 3

login
register
mail settings
Submitter phabricator
Date May 8, 2018, 8:22 p.m.
Message ID <9a5f546f881d1d664864b1c6a0a7a7ea@localhost.localdomain>
Download mbox | patch
Permalink /patch/31413/
State Not Applicable
Headers show

Comments

phabricator - May 8, 2018, 8:22 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG2b3b6187c316: tests: port test-cbor.py to Python 3 (authored by durin42, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D3505?vs=8573&id=8581

REVISION DETAIL
  https://phab.mercurial-scm.org/D3505

AFFECTED FILES
  contrib/python3-whitelist
  tests/test-cbor.py

CHANGE DETAILS




To: durin42, pulkit, #hg-reviewers, indygreg
Cc: mercurial-devel

Patch

diff --git a/tests/test-cbor.py b/tests/test-cbor.py
--- a/tests/test-cbor.py
+++ b/tests/test-cbor.py
@@ -69,7 +69,7 @@ 
 
         dest = b''.join(cborutil.streamencodeindefinitebytestring(
             source, chunksize=42))
-        self.assertEqual(cbor.loads(dest), b''.join(source))
+        self.assertEqual(cbor.loads(dest), source)
 
     def testreadtoiter(self):
         source = io.BytesIO(b'\x5f\x44\xaa\xbb\xcc\xdd\x43\xee\xff\x99\xff')
diff --git a/contrib/python3-whitelist b/contrib/python3-whitelist
--- a/contrib/python3-whitelist
+++ b/contrib/python3-whitelist
@@ -36,6 +36,7 @@ 
 test-cappedreader.py
 test-casecollision.t
 test-cat.t
+test-cbor.py
 test-censor.t
 test-changelog-exec.t
 test-check-commit.t