mirror of
https://github.com/sigp/lighthouse.git
synced 2026-05-07 16:55:46 +00:00
Run rustfmt on entire codebase
Signed-off-by: Paul Hauner <paul@paulhauner.com>
This commit is contained in:
@@ -137,9 +137,9 @@ impl From<BeaconNodeError> for Error {
|
||||
mod tests {
|
||||
use super::test_node::TestBeaconNode;
|
||||
use super::*;
|
||||
use crate::duties::EpochDuties;
|
||||
use slot_clock::TestingSlotClock;
|
||||
use types::test_utils::{SeedableRng, TestRandom, XorShiftRng};
|
||||
use crate::duties::EpochDuties;
|
||||
|
||||
// TODO: implement more thorough testing.
|
||||
//
|
||||
|
||||
@@ -16,7 +16,9 @@ impl<T: SlotClock, U: BeaconNode> BlockProducerService<T, U> {
|
||||
Err(error) => {
|
||||
error!(self.log, "Block producer poll error"; "error" => format!("{:?}", error))
|
||||
}
|
||||
Ok(BlockProducerPollOutcome::BlockProduced(slot)) => info!(self.log, "Produced block"; "slot" => slot),
|
||||
Ok(BlockProducerPollOutcome::BlockProduced(slot)) => {
|
||||
info!(self.log, "Produced block"; "slot" => slot)
|
||||
}
|
||||
Ok(BlockProducerPollOutcome::SlashableBlockNotProduced(slot)) => {
|
||||
warn!(self.log, "Slashable block was not signed"; "slot" => slot)
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
use super::traits::{BeaconNode, BeaconNodeError};
|
||||
use types::BeaconBlock;
|
||||
use std::sync::RwLock;
|
||||
use types::BeaconBlock;
|
||||
|
||||
type ProduceResult = Result<Option<BeaconBlock>, BeaconNodeError>;
|
||||
type PublishResult = Result<bool, BeaconNodeError>;
|
||||
@@ -28,7 +28,7 @@ impl BeaconNode for TestBeaconNode {
|
||||
*self.produce_input.write().unwrap() = Some(slot);
|
||||
match *self.produce_result.read().unwrap() {
|
||||
Some(ref r) => r.clone(),
|
||||
None => panic!("TestBeaconNode: produce_result == None")
|
||||
None => panic!("TestBeaconNode: produce_result == None"),
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,7 +36,7 @@ impl BeaconNode for TestBeaconNode {
|
||||
*self.publish_input.write().unwrap() = Some(block);
|
||||
match *self.publish_result.read().unwrap() {
|
||||
Some(ref r) => r.clone(),
|
||||
None => panic!("TestBeaconNode: publish_result == None")
|
||||
None => panic!("TestBeaconNode: publish_result == None"),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user