mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 14:38:29 +01:00
tests: Add missing locks to tests
Add missing locks to tests to satisfy lock requirements (such as EXCLUSIVE_LOCKS_REQUIRED(...) (Clang Thread Safety Analysis), AssertLockHeld(...) and implicit lock assumptions).
This commit is contained in:
@@ -165,6 +165,7 @@ BOOST_AUTO_TEST_CASE(MempoolIndexingTest)
|
||||
sortedOrder[2] = tx1.GetHash().ToString(); // 10000
|
||||
sortedOrder[3] = tx4.GetHash().ToString(); // 15000
|
||||
sortedOrder[4] = tx2.GetHash().ToString(); // 20000
|
||||
LOCK(pool.cs);
|
||||
CheckSort<descendant_score>(pool, sortedOrder);
|
||||
|
||||
/* low fee but with high fee child */
|
||||
@@ -375,6 +376,7 @@ BOOST_AUTO_TEST_CASE(MempoolAncestorIndexingTest)
|
||||
}
|
||||
sortedOrder[4] = tx3.GetHash().ToString(); // 0
|
||||
|
||||
LOCK(pool.cs);
|
||||
CheckSort<ancestor_score>(pool, sortedOrder);
|
||||
|
||||
/* low fee parent with high fee child */
|
||||
|
||||
Reference in New Issue
Block a user