diff options
| author | Daniel Kraft <[email protected]> | 2018-07-11 18:17:08 +0200 |
|---|---|---|
| committer | Daniel Kraft <[email protected]> | 2018-07-11 18:17:08 +0200 |
| commit | b9f4b211df24fed85dddbe69355648b57fd331ac (patch) | |
| tree | 077311327fda9335a2b1c35d7288f0f6e12f60e7 | |
| parent | Merge #13622: Remove mapRequest tracking that just effects Qt display. (diff) | |
| download | discoin-b9f4b211df24fed85dddbe69355648b57fd331ac.tar.xz discoin-b9f4b211df24fed85dddbe69355648b57fd331ac.zip | |
tests: Use MAX_SCRIPT_ELEMENT_SIZE from script.py
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.
| -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 727f2d1c6..6c0bb1430 100755 --- a/test/functional/p2p_segwit.py +++ b/test/functional/p2p_segwit.py @@ -46,6 +46,7 @@ from test_framework.script import ( CScript, CScriptNum, CScriptOp, + MAX_SCRIPT_ELEMENT_SIZE, OP_0, OP_1, OP_16, @@ -1137,8 +1138,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]) |