Changeset View
Changeset View
Standalone View
Standalone View
test/functional/feature_bip68_sequence.py
#!/usr/bin/env python3 | #!/usr/bin/env python3 | ||||
# Copyright (c) 2014-2016 The Bitcoin Core developers | # Copyright (c) 2014-2016 The Bitcoin Core developers | ||||
# Distributed under the MIT software license, see the accompanying | # Distributed under the MIT software license, see the accompanying | ||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php. | # file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
# | # | ||||
# Test BIP68 implementation | # Test BIP68 implementation | ||||
# | # | ||||
from test_framework.test_framework import BitcoinTestFramework | from test_framework.test_framework import BitcoinTestFramework | ||||
from test_framework.util import * | from test_framework.util import * | ||||
from test_framework.script import * | from test_framework.script import * | ||||
from test_framework.mininode import * | from test_framework.mininode import * | ||||
from test_framework.blocktools import * | from test_framework.blocktools import * | ||||
from test_framework.txtools import pad_tx, pad_raw_tx | from test_framework.txtools import pad_tx | ||||
SEQUENCE_LOCKTIME_DISABLE_FLAG = (1 << 31) | SEQUENCE_LOCKTIME_DISABLE_FLAG = (1 << 31) | ||||
SEQUENCE_LOCKTIME_TYPE_FLAG = (1 << 22) # this means use time (0 means height) | SEQUENCE_LOCKTIME_TYPE_FLAG = (1 << 22) # this means use time (0 means height) | ||||
SEQUENCE_LOCKTIME_GRANULARITY = 9 # this is a bit-shift | SEQUENCE_LOCKTIME_GRANULARITY = 9 # this is a bit-shift | ||||
SEQUENCE_LOCKTIME_MASK = 0x0000ffff | SEQUENCE_LOCKTIME_MASK = 0x0000ffff | ||||
# RPC error for non-BIP68 final transactions | # RPC error for non-BIP68 final transactions | ||||
NOT_FINAL_ERROR = "64: non-BIP68-final" | NOT_FINAL_ERROR = "64: non-BIP68-final" | ||||
▲ Show 20 Lines • Show All 448 Lines • Show Last 20 Lines |