aboutsummaryrefslogtreecommitdiff
path: root/src/test/util/index.cpp
blob: 89bc35b7316746a0db4495b1e7759fad903a5289 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// Copyright (c) 2020-2022 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.

#include <test/util/index.h>

#include <index/base.h>
#include <util/time.h>

void IndexWaitSynced(const BaseIndex& index)
{
    while (!index.BlockUntilSyncedToCurrentChain()) {
        UninterruptibleSleep(100ms);
    }
}