dash/qa/rpc-tests/test_framework
Alexander Block 5299d39338 Multiple refactorings/fixes for LLMQ bases InstantSend and ChainLocks (#2779)
* Remove unused parameters from CInstantSendManager::ProcessTx

* Pass txHash in CheckCanLock by reference instead of pointer

* Dont' allow locking of TXs without inputs

* Remove unused local variable nInstantSendConfirmationsRequired

* Don't subtract 1 from nInstantSendConfirmationsRequired

This was necessary in the old system but is not necessary in the new system.
It also prevented proper retroactive signing of chained TXs in regtest as
it resulted in child TXs to return true immediately for CheckCanLock when
it should actually have waited for the parent TX to become locked first.

* Access chainActive.Height() while cs_main is locked

* Properly read and write lastChainLockBlock

"pindex" is NOT the chainlocked block after the while loop finishes. We
must use the pindex (renamed to pindexChainLock now) given on method entry.

Also, the GetLastChainLockBlock() result was not assigned to,
lastChainLockBlock which resulted in the while loop to run unnecessarily
long.

* Generalize filtering in NewPoWValidBlock and SyncTransaction

We're actually interested in all TXs that have inputs, so no need to
explicitly check for tx types.

* Use tx.IsCoinBase() instead of checking for index 0

* Handle cases where a TX is not received yet in wait_for_instantlock

* Wait on all nodes for the locks

Otherwise we end up with the sender having it locked but other nodes
not yet, failing the test.

* Fix LogPrintf call in CChainLocksHandler::DoInvalidateBlock
2019-03-19 10:38:16 +03:00
..
__init__.py [QA] restructure rpc tests directory 2015-05-18 15:25:45 +02:00
authproxy.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
bignum.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
blockstore.py Merge #9768: [qa] Add logging to test_framework.py 2019-02-26 15:54:32 -06:00
blocktools.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
comptool.py code review and reset file perms 2019-03-03 20:50:39 -06:00
coverage.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
key.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
mininode.py Merge #11113: [net] Ignore getheaders requests for very old side blocks 2019-03-12 10:43:47 +01:00
netutil.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
script.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
siphash.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
socks5.py Backports 0.15 pr2 (#2597) 2019-01-07 12:55:35 +03:00
test_framework.py Multiple refactorings/fixes for LLMQ bases InstantSend and ChainLocks (#2779) 2019-03-19 10:38:16 +03:00
util.py Merge bitcoin#9602: Remove coin age priority and free transactions - implementation (#2768) 2019-03-14 17:44:42 +03:00