Page MenuHomePhabricator

test: fix intermittent mempool_unbroadcast txn-mempool-conflict
ClosedPublic

Authored by PiRK on Jan 22 2021, 01:33.

Details

Summary

A list of available UTXOs was generated, then a transaction was generated with sendtoaddress, then a second transaction was constructed from the first UTXO in the list. Due to the randomness in the coin selection algorithm, there was no guarantee that the transactions didn't spend the same UTXO.

This revision makes sure that the list of available UTXOs used to construct the second transaction is requested from the node after it has already sent the first transaction. This should guarantee that the second transaction never spends the same UTXO.

Test Plan

for i in {1..20}; do test/functional/test_runner.py mempool_u*; done

Diff Detail

Repository
rABC Bitcoin ABC
Branch
fix_mempool_unbroadcast
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 14925
Build 29802: Build Diffbuild-without-wallet · build-debug · build-clang · build-clang-tidy · build-diff
Build 29801: arc lint + arc unit