Skip to content

Commit 6b56848

Browse files
committed
ensure CurveEdTw hashability
1 parent 8125ca2 commit 6b56848

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/ecdsa/test_ellipticcurve.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,12 @@ def test___str___with_cofactor(self):
117117
c = CurveEdTw(23, 1, 1, 4)
118118
self.assertEqual(str(c), "CurveEdTw(p=23, a=1, d=1, h=4)")
119119

120+
def test_usability_in_a_hashed_collection_curves(self):
121+
{self.c_23: None}
122+
123+
def test_hashability_curves(self):
124+
hash(self.c_23)
125+
120126

121127
class TestPoint(unittest.TestCase):
122128
@classmethod

0 commit comments

Comments
 (0)