mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-12 19:21:13 +00:00
Mass replace ,); pattern (#3580)
This is an artifact left by rustfmt which is not dare to remove the comma being conservative.
This commit is contained in:
@@ -481,7 +481,7 @@ mod tests {
|
||||
.write(vec![BackendWriteOp::DeleteBlockEntry(block_entry.block_hash)])
|
||||
.unwrap();
|
||||
|
||||
assert!(backend.load_block_entry(&block_entry.block_hash).unwrap().is_none(),);
|
||||
assert!(backend.load_block_entry(&block_entry.block_hash).unwrap().is_none());
|
||||
}
|
||||
|
||||
#[test]
|
||||
@@ -491,7 +491,7 @@ mod tests {
|
||||
|
||||
let mut backend = DbBackend::new(db, config);
|
||||
|
||||
assert!(backend.load_first_block_number().unwrap().is_none(),);
|
||||
assert!(backend.load_first_block_number().unwrap().is_none());
|
||||
|
||||
backend
|
||||
.write(vec![
|
||||
@@ -501,7 +501,7 @@ mod tests {
|
||||
])
|
||||
.unwrap();
|
||||
|
||||
assert_eq!(backend.load_first_block_number().unwrap(), Some(2),);
|
||||
assert_eq!(backend.load_first_block_number().unwrap(), Some(2));
|
||||
|
||||
backend
|
||||
.write(vec![
|
||||
@@ -510,7 +510,7 @@ mod tests {
|
||||
])
|
||||
.unwrap();
|
||||
|
||||
assert_eq!(backend.load_first_block_number().unwrap(), Some(10),);
|
||||
assert_eq!(backend.load_first_block_number().unwrap(), Some(10));
|
||||
}
|
||||
|
||||
#[test]
|
||||
@@ -521,7 +521,7 @@ mod tests {
|
||||
let mut backend = DbBackend::new(db, config);
|
||||
|
||||
// Prove that it's cheap
|
||||
assert!(backend.load_stagnant_at_up_to(Timestamp::max_value()).unwrap().is_empty(),);
|
||||
assert!(backend.load_stagnant_at_up_to(Timestamp::max_value()).unwrap().is_empty());
|
||||
|
||||
backend
|
||||
.write(vec![
|
||||
@@ -584,9 +584,9 @@ mod tests {
|
||||
])
|
||||
.unwrap();
|
||||
|
||||
assert_eq!(backend.load_blocks_by_number(2).unwrap(), vec![Hash::repeat_byte(1)],);
|
||||
assert_eq!(backend.load_blocks_by_number(2).unwrap(), vec![Hash::repeat_byte(1)]);
|
||||
|
||||
assert_eq!(backend.load_blocks_by_number(3).unwrap(), vec![],);
|
||||
assert_eq!(backend.load_blocks_by_number(3).unwrap(), vec![]);
|
||||
|
||||
backend
|
||||
.write(vec![
|
||||
@@ -595,10 +595,10 @@ mod tests {
|
||||
])
|
||||
.unwrap();
|
||||
|
||||
assert_eq!(backend.load_blocks_by_number(2).unwrap(), vec![],);
|
||||
assert_eq!(backend.load_blocks_by_number(2).unwrap(), vec![]);
|
||||
|
||||
assert_eq!(backend.load_blocks_by_number(5).unwrap(), vec![],);
|
||||
assert_eq!(backend.load_blocks_by_number(5).unwrap(), vec![]);
|
||||
|
||||
assert_eq!(backend.load_blocks_by_number(10).unwrap(), vec![Hash::repeat_byte(3)],);
|
||||
assert_eq!(backend.load_blocks_by_number(10).unwrap(), vec![Hash::repeat_byte(3)]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -497,7 +497,7 @@ async fn handle_active_leaf(
|
||||
|
||||
let header = match fetch_header(ctx, hash).await? {
|
||||
None => {
|
||||
tracing::warn!(target: LOG_TARGET, ?hash, "Missing header for new head",);
|
||||
tracing::warn!(target: LOG_TARGET, ?hash, "Missing header for new head");
|
||||
return Ok(Vec::new())
|
||||
},
|
||||
Some(h) => h,
|
||||
|
||||
@@ -551,7 +551,7 @@ fn assert_backend_contains<'a>(
|
||||
header.number,
|
||||
hash,
|
||||
);
|
||||
assert!(backend.load_block_entry(&hash).unwrap().is_some(), "no entry found for {}", hash,);
|
||||
assert!(backend.load_block_entry(&hash).unwrap().is_some(), "no entry found for {}", hash);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1138,9 +1138,9 @@ fn finalize_viable_prunes_subtrees() {
|
||||
assert_leaves(&backend, vec![a3_hash, x3_hash]);
|
||||
assert_leaves_query(&mut virtual_overseer, vec![a3_hash, x3_hash]).await;
|
||||
|
||||
assert_eq!(backend.load_first_block_number().unwrap().unwrap(), 3,);
|
||||
assert_eq!(backend.load_first_block_number().unwrap().unwrap(), 3);
|
||||
|
||||
assert_eq!(backend.load_blocks_by_number(3).unwrap(), vec![a3_hash, x3_hash],);
|
||||
assert_eq!(backend.load_blocks_by_number(3).unwrap(), vec![a3_hash, x3_hash]);
|
||||
|
||||
virtual_overseer
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user