Skip to content

Commit

Permalink
test table type
Browse files Browse the repository at this point in the history
  • Loading branch information
kariy committed Apr 5, 2024
1 parent 1847abd commit bf93d45
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions crates/katana/storage/db/src/tables.rs
Original file line number Diff line number Diff line change
Expand Up @@ -254,5 +254,28 @@ mod tests {
assert_eq!(Tables::ALL[19].name(), ClassChangeHistory::NAME);
assert_eq!(Tables::ALL[20].name(), StorageChangeHistory::NAME);
assert_eq!(Tables::ALL[21].name(), StorageChangeSet::NAME);

assert_eq!(Tables::Headers.table_type(), TableType::Table);
assert_eq!(Tables::BlockHashes.table_type(), TableType::Table);
assert_eq!(Tables::BlockNumbers.table_type(), TableType::Table);
assert_eq!(Tables::BlockBodyIndices.table_type(), TableType::Table);
assert_eq!(Tables::BlockStatusses.table_type(), TableType::Table);
assert_eq!(Tables::TxNumbers.table_type(), TableType::Table);
assert_eq!(Tables::TxBlocks.table_type(), TableType::Table);
assert_eq!(Tables::TxHashes.table_type(), TableType::Table);
assert_eq!(Tables::Transactions.table_type(), TableType::Table);
assert_eq!(Tables::Receipts.table_type(), TableType::Table);
assert_eq!(Tables::CompiledClassHashes.table_type(), TableType::Table);
assert_eq!(Tables::CompiledClasses.table_type(), TableType::Table);
assert_eq!(Tables::SierraClasses.table_type(), TableType::Table);
assert_eq!(Tables::ContractInfo.table_type(), TableType::Table);
assert_eq!(Tables::ContractStorage.table_type(), TableType::DupSort);
assert_eq!(Tables::ClassDeclarationBlock.table_type(), TableType::Table);
assert_eq!(Tables::ClassDeclarations.table_type(), TableType::DupSort);
assert_eq!(Tables::ContractInfoChangeSet.table_type(), TableType::Table);
assert_eq!(Tables::NonceChangeHistory.table_type(), TableType::DupSort);
assert_eq!(Tables::ClassChangeHistory.table_type(), TableType::DupSort);
assert_eq!(Tables::StorageChangeHistory.table_type(), TableType::DupSort);
assert_eq!(Tables::StorageChangeSet.table_type(), TableType::Table);
}
}

0 comments on commit bf93d45

Please sign in to comment.