Encode Reasons.
diff --git a/tests/hazmat/primitives/utils.py b/tests/hazmat/primitives/utils.py
index 1dfad6e..b4a8a3e 100644
--- a/tests/hazmat/primitives/utils.py
+++ b/tests/hazmat/primitives/utils.py
@@ -154,7 +154,7 @@
key = params[2]
h = hmac.HMAC(binascii.unhexlify(key), algorithm)
h.update(binascii.unhexlify(msg))
- assert h.finalize() == binascii.unhexlify(md)
+ assert h.finalize() == binascii.unhexlify(md.encode("ascii"))
def generate_base_hmac_test(hash_cls, only_if=None, skip_message=None):