mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-09-12 21:52:53 +02:00
coins: test chainstate flush baseline
Add `CDBWrapper::GetProperty()` and expose it through `CCoinsViewDB::GetDBProperty()` so coins tests can inspect LevelDB runtime properties through the coins view. Use it in a coins DB flush baseline that records the LevelDB layout after flushing while keeping readback coverage for the flushed coin and best block. Co-authored-by: Andrew Toth <andrewstoth@gmail.com>
This commit is contained in:
@@ -175,6 +175,11 @@ size_t CCoinsViewDB::EstimateSize() const
|
||||
return m_db->EstimateSize(DB_COIN, uint8_t(DB_COIN + 1));
|
||||
}
|
||||
|
||||
std::optional<std::string> CCoinsViewDB::GetDBProperty(const std::string& property)
|
||||
{
|
||||
return m_db->GetProperty(property);
|
||||
}
|
||||
|
||||
/** Specialization of CCoinsViewCursor to iterate over a CCoinsViewDB */
|
||||
class CCoinsViewDBCursor: public CCoinsViewCursor
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user