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:
Lőrinc
2026-06-04 19:42:00 +02:00
parent c117bbc467
commit b10889d107
5 changed files with 42 additions and 2 deletions

View File

@@ -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
{