Example #1
0
 def test_invalid_phash(self):
     with raises(Address.InvalidHashLength):
         Address('a')
Example #2
0
 def test_invalid_network(self):
     with raises(Address.UnknownNetwork):
         Address('a' * 20, -1)
Example #3
0
 def test_create(self):
     Address('a' * 20, networks.livenet, Address.Type.PublicKey)
     Address('a' * 20, networks.livenet, Address.Type.Script)
     Address('a' * 20, networks.testnet, Address.Type.PublicKey)
     Address('a' * 20, networks.testnet, Address.Type.Script)