Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,8 @@

use super::*;
use crate::subscription_filter::WhitelistSubscriptionFilter;
use crate::transform::{DataTransform, IdentityTransform};
use crate::types::{RpcOut, RpcReceiver};
use crate::ValidationError;
use crate::{
config::Config, config::ConfigBuilder, types::Rpc, IdentTopic as Topic, TopicScoreParams,
};
use crate::types::RpcReceiver;
use crate::{config::ConfigBuilder, types::Rpc, IdentTopic as Topic};
use byteorder::{BigEndian, ByteOrder};
use libp2p::core::ConnectedPoint;
use rand::Rng;
Expand Down
1 change: 0 additions & 1 deletion beacon_node/lighthouse_network/gossipsub/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -903,7 +903,6 @@ impl std::fmt::Debug for Config {
mod test {
use super::*;
use crate::topic::IdentityHash;
use crate::types::PeerKind;
use crate::Topic;
use libp2p::core::UpgradeInfo;
use std::collections::hash_map::DefaultHasher;
Expand Down
4 changes: 1 addition & 3 deletions beacon_node/lighthouse_network/gossipsub/src/mcache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -221,9 +221,7 @@ impl MessageCache {
#[cfg(test)]
mod tests {
use super::*;
use crate::types::RawMessage;
use crate::{IdentTopic as Topic, TopicHash};
use libp2p::identity::PeerId;
use crate::IdentTopic as Topic;

fn gen_testm(x: u64, topic: TopicHash) -> (MessageId, RawMessage) {
let default_id = |message: &RawMessage| {
Expand Down
1 change: 0 additions & 1 deletion beacon_node/lighthouse_network/gossipsub/src/protocol.rs
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,6 @@ impl Decoder for GossipsubCodec {
mod tests {
use super::*;
use crate::config::Config;
use crate::protocol::{BytesMut, GossipsubCodec, HandlerEvent};
use crate::{Behaviour, ConfigBuilder, MessageAuthenticity};
use crate::{IdentTopic as Topic, Version};
use libp2p::identity::Keypair;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,6 @@ impl TopicSubscriptionFilter for RegexSubscriptionFilter {
mod test {
use super::*;
use crate::types::SubscriptionAction::*;
use std::iter::FromIterator;

#[test]
fn test_filter_incoming_allow_all_with_duplicates() {
Expand Down
4 changes: 2 additions & 2 deletions beacon_node/operation_pool/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -721,7 +721,7 @@ impl<E: EthSpec> OperationPool<E> {
}

/// Filter up to a maximum number of operations out of an iterator.
fn filter_limit_operations<'a, T: 'a, V: 'a, I, F, G>(
fn filter_limit_operations<'a, T, V: 'a, I, F, G>(
operations: I,
filter: F,
mapping: G,
Expand All @@ -731,7 +731,7 @@ where
I: IntoIterator<Item = &'a T>,
F: Fn(&T) -> bool,
G: Fn(&T) -> V,
T: Clone,
T: Clone + 'a,
{
operations
.into_iter()
Expand Down
1 change: 0 additions & 1 deletion consensus/types/src/chain_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1651,7 +1651,6 @@ where
mod tests {
use super::*;
use itertools::Itertools;
use safe_arith::SafeArith;

#[test]
fn test_mainnet_spec_can_be_constructed() {
Expand Down
4 changes: 2 additions & 2 deletions testing/ef_tests/src/cases/fork_choice.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ use std::sync::Arc;
use std::time::Duration;
use types::{
Attestation, AttesterSlashing, BeaconBlock, BeaconState, BlobSidecar, BlobsList, Checkpoint,
EthSpec, ExecutionBlockHash, ForkName, Hash256, IndexedAttestation, KzgProof,
ProposerPreparationData, SignedBeaconBlock, Slot, Uint256,
ExecutionBlockHash, Hash256, IndexedAttestation, KzgProof, ProposerPreparationData,
SignedBeaconBlock, Slot, Uint256,
};

#[derive(Default, Debug, PartialEq, Clone, Deserialize, Decode)]
Expand Down
3 changes: 1 addition & 2 deletions testing/ef_tests/src/cases/rewards.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@ use state_processing::{
},
EpochProcessingError,
};
use std::path::{Path, PathBuf};
use types::{BeaconState, EthSpec, ForkName};
use types::BeaconState;

#[derive(Debug, Clone, PartialEq, Decode, Encode, CompareFields)]
pub struct Deltas {
Expand Down