Patchwork D8373: manifest: add test for long hashes

login
register
mail settings
Submitter phabricator
Date April 2, 2020, 8:32 p.m.
Message ID <differential-rev-PHID-DREV-xzf7twzv3jwpbvyn3qvp-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/46004/
State Superseded
Headers show

Comments

phabricator - April 2, 2020, 8:32 p.m.
durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REPOSITORY
  rHG Mercurial

BRANCH
  default

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

AFFECTED FILES
  tests/test-manifest.py

CHANGE DETAILS




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

Patch

diff --git a/tests/test-manifest.py b/tests/test-manifest.py
--- a/tests/test-manifest.py
+++ b/tests/test-manifest.py
@@ -88,6 +88,10 @@ 
         with self.assertRaises(KeyError):
             m[b'wat']
 
+    def testManifestLongHashes(self):
+        m = self.parsemanifest(b'a\0' + b'f' * 64 + b'\n')
+        self.assertEqual(binascii.unhexlify(b'f' * 64), m[b'a'])
+
     def testSetItem(self):
         want = BIN_HASH_1