mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-17 13:07:54 +02:00
Add required locks in tests
Unit tests with DEBUG_LOCKORDER were running into assertions.
This commit is contained in:
parent
bbe53f61db
commit
ed67100565
3 changed files with 5 additions and 1 deletions
|
|
@ -50,6 +50,7 @@ BOOST_AUTO_TEST_SUITE(script_P2SH_tests)
|
|||
|
||||
BOOST_AUTO_TEST_CASE(sign)
|
||||
{
|
||||
LOCK(cs_main);
|
||||
// Pay-to-script-hash looks like this:
|
||||
// scriptSig: <sig> <sig...> <serialized_script>
|
||||
// scriptPubKey: HASH160 <hash> EQUAL
|
||||
|
|
@ -147,6 +148,7 @@ BOOST_AUTO_TEST_CASE(norecurse)
|
|||
|
||||
BOOST_AUTO_TEST_CASE(set)
|
||||
{
|
||||
LOCK(cs_main);
|
||||
// Test the CScript::Set* methods
|
||||
CBasicKeyStore keystore;
|
||||
CKey key[4];
|
||||
|
|
@ -250,6 +252,7 @@ BOOST_AUTO_TEST_CASE(switchover)
|
|||
|
||||
BOOST_AUTO_TEST_CASE(AreInputsStandard)
|
||||
{
|
||||
LOCK(cs_main);
|
||||
CCoinsView coinsDummy;
|
||||
CCoinsViewCache coins(coinsDummy);
|
||||
CBasicKeyStore keystore;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue