diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-07-17 17:30:35 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-07-17 17:53:20 +0200 |
commit | 6fcdb5ebdd71b8b0fed3df0fd6aa3639bcb87a0b (patch) | |
tree | 07950ec84a94471c83879afeb1607e575410231e /test/functional | |
parent | 30640f8c2da5884b8806422f4d5511ae03a1550e (diff) | |
parent | b9f4b211df24fed85dddbe69355648b57fd331ac (diff) |
Merge #13638: tests: Use MAX_SCRIPT_ELEMENT_SIZE from script.py
b9f4b211df24fed85dddbe69355648b57fd331ac tests: Use MAX_SCRIPT_ELEMENT_SIZE from script.py (Daniel Kraft)
Pull request description:
`p2p_segwit.py` and `test_framework/script.py` both define a constant for `MAX_SCRIPT_ELEMENT_SIZE` (=520 bytes), which is redundant. This change uses the constant defined in the `script.py` module for `p2p_segwit.py`.
Tree-SHA512: 2bc295ff26d9b052d4e05b85c27e748175884d6689a92c19337fc4db8bf439e3abe3edc91af1aaf46d8dc42ed96a85ad17110546d2274a0d9cda3abd6b878a31
Diffstat (limited to 'test/functional')
-rwxr-xr-x | test/functional/p2p_segwit.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/test/functional/p2p_segwit.py b/test/functional/p2p_segwit.py index 801c4b87a0..52f6482d56 100755 --- a/test/functional/p2p_segwit.py +++ b/test/functional/p2p_segwit.py @@ -47,6 +47,7 @@ from test_framework.script import ( CScript, CScriptNum, CScriptOp, + MAX_SCRIPT_ELEMENT_SIZE, OP_0, OP_1, OP_16, @@ -1129,8 +1130,6 @@ class SegWitTest(BitcoinTestFramework): def test_max_witness_push_length(self): """Test that witness stack can only allow up to 520 byte pushes.""" - MAX_SCRIPT_ELEMENT_SIZE = 520 - block = self.build_next_block() witness_program = CScript([OP_DROP, OP_TRUE]) |