mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-07-04 13:02:47 -05:00
Add some tests of Miller-Rabin to cryptsuite.
I'm about to rewrite the Miller-Rabin testing code, so let's start by introducing a test suite that the old version passes, and then I can make sure the new one does too.
This commit is contained in:
@ -235,7 +235,7 @@ def make_retval(rettype, word, unpack_strings):
|
||||
elif rettype == "boolean":
|
||||
assert word == b"true" or word == b"false"
|
||||
return word == b"true"
|
||||
elif rettype == "pocklestatus":
|
||||
elif rettype in {"pocklestatus", "mr_result"}:
|
||||
return word.decode("ASCII")
|
||||
raise TypeError("Can't deal with return value {!r} of type {!r}"
|
||||
.format(word, rettype))
|
||||
|
Reference in New Issue
Block a user