summaryrefslogtreecommitdiff
path: root/tests/test_misc.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2014-12-12 08:51:19 -0500
committerNed Batchelder <ned@nedbatchelder.com>2014-12-12 08:51:19 -0500
commit6055667e8090fc09e55b96ae49d5ac6a37706ede (patch)
tree12eba2ac0b9cb22476de8ec3d3eb9a6d183ad0b2 /tests/test_misc.py
parent24e2488c36e4d19fd9eb06a5b03cd92821b4f2bd (diff)
downloadpython-coveragepy-git-6055667e8090fc09e55b96ae49d5ac6a37706ede.tar.gz
Source is always Unicode in HTML code. More refactoring to come.
Diffstat (limited to 'tests/test_misc.py')
-rw-r--r--tests/test_misc.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/test_misc.py b/tests/test_misc.py
index 7b7d51d0..d9b0c4e6 100644
--- a/tests/test_misc.py
+++ b/tests/test_misc.py
@@ -22,6 +22,13 @@ class HasherTest(CoverageTest):
self.assertNotEqual(h1.hexdigest(), h2.hexdigest())
self.assertEqual(h1.hexdigest(), h3.hexdigest())
+ def test_bytes_hashing(self):
+ h1 = Hasher()
+ h1.update(b"Hello, world!")
+ h2 = Hasher()
+ h2.update(b"Goodbye!")
+ self.assertNotEqual(h1.hexdigest(), h2.hexdigest())
+
def test_dict_hashing(self):
h1 = Hasher()
h1.update({'a': 17, 'b': 23})