mirror of
https://github.com/talaia-labs/rust-teos.git
synced 2026-08-13 12:33:22 +02:00
cargo fix
Signed-off-by: dzdidi <dzdidi@protonmail.com>
This commit is contained in:
parent
25e8727a16
commit
6396d61ba5
2 changed files with 4 additions and 4 deletions
|
|
@ -190,7 +190,7 @@ mod tests {
|
|||
use teos_common::test_utils::{TXID_HEX, TX_HEX};
|
||||
|
||||
use bitcoin::consensus;
|
||||
use bitcoin::hashes::Hash;
|
||||
|
||||
use bitcoin::hashes::hex::FromHex;
|
||||
use bitcoincore_rpc::Auth;
|
||||
|
||||
|
|
|
|||
|
|
@ -342,7 +342,7 @@ mod tests {
|
|||
// Store the last block to use it for an update and the first to check eviction
|
||||
// Notice that the list of blocks is ordered from last to first.
|
||||
let last_block = last_n_blocks.remove(0);
|
||||
let first_block = last_n_blocks.last().unwrap().deref().clone();
|
||||
let first_block = last_n_blocks.last().unwrap().deref();
|
||||
|
||||
// Init the cache with the 6 block before the last
|
||||
let mut cache = TxIndex::new(&last_n_blocks, height);
|
||||
|
|
@ -383,7 +383,7 @@ mod tests {
|
|||
);
|
||||
|
||||
// Check that the data from the first block has been evicted
|
||||
let tx = match first_block.deref() {
|
||||
let tx = match first_block {
|
||||
lightning_block_sync::BlockData::FullBlock(b) => b.txdata[0].clone(),
|
||||
lightning_block_sync::BlockData::HeaderOnly(_) => {
|
||||
panic!("Expected FullBlock")
|
||||
|
|
@ -391,7 +391,7 @@ mod tests {
|
|||
};
|
||||
assert!(!cache.contains_key(&Locator::new(tx.txid())));
|
||||
|
||||
let block_hash = match first_block.deref() {
|
||||
let block_hash = match first_block {
|
||||
lightning_block_sync::BlockData::FullBlock(b) => b.header.block_hash(),
|
||||
lightning_block_sync::BlockData::HeaderOnly(h) => h.block_hash(),
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue