コード例 #1
0
 def test_invalid_secret_and_key_type(self):
     with self.assertRaises(XRPLModelException):
         Sign(
             transaction=_TRANSACTION,
             secret=_SECRET,
             key_type="secp256k1",
         )
コード例 #2
0
 def test_invalid_secret_and_passphrase(self):
     with self.assertRaises(XRPLModelException):
         Sign(
             transaction=_TRANSACTION,
             secret=_SECRET,
             passphrase=_PASSPHRASE,
         )
コード例 #3
0
 def test_invalid_seed_hex_and_passphrase(self):
     with self.assertRaises(XRPLModelException):
         Sign(
             transaction=_TRANSACTION,
             seed_hex=_SEED_HEX,
             passphrase=_PASSPHRASE,
         )
コード例 #4
0
 def test_invalid_seed_and_seed_hex(self):
     with self.assertRaises(XRPLModelException):
         Sign(
             transaction=_TRANSACTION,
             seed=_SEED,
             seed_hex=_SEED_HEX,
         )
コード例 #5
0
 def test_valid_seed(self):
     request = Sign(transaction=_TRANSACTION,
                    seed=_SEED,
                    key_type=CryptoAlgorithm.SECP256K1)
     self.assertTrue(request.is_valid())
コード例 #6
0
 def test_valid_secret(self):
     request = Sign(
         transaction=_TRANSACTION,
         secret=_SECRET,
     )
     self.assertTrue(request.is_valid())
コード例 #7
0
 def test_invalid_secret_and_seed(self):
     with self.assertRaises(XRPLModelException):
         Sign(transaction=_TRANSACTION, secret=_SECRET, seed=_SEED)