test_wormhole: more coverage

This commit is contained in:
Brian Warner 2017-04-17 17:15:35 -04:00
parent 16c47de61b
commit 0774ac8c36

View File

@ -100,6 +100,11 @@ class Wormholes(ServerBase, unittest.TestCase):
yield w1.when_key()
yield w2.when_key()
with self.assertRaises(TypeError):
w1.derive_key(b"not unicode", 16)
with self.assertRaises(TypeError):
w1.derive_key(12345, 16)
verifier1 = yield w1.when_verified()
verifier2 = yield w2.when_verified()
self.assertEqual(verifier1, verifier2)