diff options
author | Sebastian Falbesoner <sebastian.falbesoner@gmail.com> | 2021-07-26 00:33:58 +0200 |
---|---|---|
committer | Sebastian Falbesoner <sebastian.falbesoner@gmail.com> | 2021-07-27 00:14:57 +0200 |
commit | 12f094ec215aacf30e4e380c0399f80d4e45c345 (patch) | |
tree | c7a82daf4a3b2e84350871bc985b79477d78c213 /test/functional/rpc_signrawtransaction.py | |
parent | 746f203f1950a7df50b9a7de87a361cc7354ffb4 (diff) |
test: use constants for CSV/CLTV activation heights in rpc_signrawtransaction
Diffstat (limited to 'test/functional/rpc_signrawtransaction.py')
-rwxr-xr-x | test/functional/rpc_signrawtransaction.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/test/functional/rpc_signrawtransaction.py b/test/functional/rpc_signrawtransaction.py index dacd7b9c5e..571029155e 100755 --- a/test/functional/rpc_signrawtransaction.py +++ b/test/functional/rpc_signrawtransaction.py @@ -4,7 +4,11 @@ # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test transaction signing using the signrawtransaction* RPCs.""" -from test_framework.blocktools import COINBASE_MATURITY +from test_framework.blocktools import ( + CLTV_HEIGHT, + COINBASE_MATURITY, + CSV_ACTIVATION_HEIGHT, +) from test_framework.address import ( script_to_p2sh, script_to_p2wsh, @@ -271,7 +275,7 @@ class SignRawTransactionsTest(BitcoinTestFramework): getcontext().prec = 8 # Make sure CSV is active - generate_to_height(self.nodes[0], 500) + generate_to_height(self.nodes[0], CSV_ACTIVATION_HEIGHT) assert self.nodes[0].getblockchaininfo()['softforks']['csv']['active'] # Create a P2WSH script with CSV @@ -307,7 +311,7 @@ class SignRawTransactionsTest(BitcoinTestFramework): getcontext().prec = 8 # Make sure CLTV is active - generate_to_height(self.nodes[0], 1500) + generate_to_height(self.nodes[0], CLTV_HEIGHT) assert self.nodes[0].getblockchaininfo()['softforks']['bip65']['active'] # Create a P2WSH script with CLTV |