Skip to content

Commit

Permalink
chore(sidecar): test
Browse files Browse the repository at this point in the history
  • Loading branch information
namn-grg committed Jul 19, 2024
1 parent bdbe371 commit 75f4dfe
Showing 1 changed file with 7 additions and 35 deletions.
42 changes: 7 additions & 35 deletions bolt-sidecar/src/state/execution.rs
Original file line number Diff line number Diff line change
Expand Up @@ -482,11 +482,7 @@ mod tests {
let anvil = launch_anvil();
let client = StateClient::new(anvil.endpoint_url());

let limits: Limits = Limits {
max_commitments_per_slot: NonZero::new(10).unwrap(),
max_committed_gas_per_slot: NonZero::new(10_000_000).unwrap(),
};
let mut state = ExecutionState::new(client.clone(), limits).await?;
let mut state = ExecutionState::new(client.clone(), Limits::default()).await?;

let sender = anvil.addresses().first().unwrap();
let sender_pk = anvil.keys().first().unwrap();
Expand All @@ -511,11 +507,7 @@ mod tests {
let anvil = launch_anvil();
let client = StateClient::new(anvil.endpoint_url());

let limits: Limits = Limits {
max_commitments_per_slot: NonZero::new(10).unwrap(),
max_committed_gas_per_slot: NonZero::new(10_000_000).unwrap(),
};
let mut state = ExecutionState::new(client.clone(), limits).await?;
let mut state = ExecutionState::new(client.clone(), Limits::default()).await?;

let sender = anvil.addresses().first().unwrap();
let sender_pk = anvil.keys().first().unwrap();
Expand Down Expand Up @@ -555,11 +547,7 @@ mod tests {
let anvil = launch_anvil();
let client = StateClient::new(anvil.endpoint_url());

let limits: Limits = Limits {
max_commitments_per_slot: NonZero::new(10).unwrap(),
max_committed_gas_per_slot: NonZero::new(10_000_000).unwrap(),
};
let mut state = ExecutionState::new(client.clone(), limits).await?;
let mut state = ExecutionState::new(client.clone(), Limits::default()).await?;

let sender = anvil.addresses().first().unwrap();
let sender_pk = anvil.keys().first().unwrap();
Expand Down Expand Up @@ -645,11 +633,7 @@ mod tests {
let anvil = launch_anvil();
let client = StateClient::new(anvil.endpoint_url());

let limits: Limits = Limits {
max_commitments_per_slot: NonZero::new(10).unwrap(),
max_committed_gas_per_slot: NonZero::new(10_000_000).unwrap(),
};
let mut state = ExecutionState::new(client.clone(), limits).await?;
let mut state = ExecutionState::new(client.clone(), Limits::default()).await?;

let sender = anvil.addresses().first().unwrap();
let sender_pk = anvil.keys().first().unwrap();
Expand Down Expand Up @@ -711,11 +695,7 @@ mod tests {
let anvil = launch_anvil();
let client = StateClient::new(anvil.endpoint_url());

let limits: Limits = Limits {
max_commitments_per_slot: NonZero::new(10).unwrap(),
max_committed_gas_per_slot: NonZero::new(10_000_000).unwrap(),
};
let mut state = ExecutionState::new(client.clone(), limits).await?;
let mut state = ExecutionState::new(client.clone(), Limits::default()).await?;

let basefee = state.basefee();

Expand Down Expand Up @@ -781,11 +761,7 @@ mod tests {
let client = StateClient::new(anvil.endpoint_url());
let provider = ProviderBuilder::new().on_http(anvil.endpoint_url());

let limits: Limits = Limits {
max_commitments_per_slot: NonZero::new(10).unwrap(),
max_committed_gas_per_slot: NonZero::new(10_000_000).unwrap(),
};
let mut state = ExecutionState::new(client.clone(), limits).await?;
let mut state = ExecutionState::new(client.clone(), Limits::default()).await?;

let sender = anvil.addresses().first().unwrap();
let sender_pk = anvil.keys().first().unwrap();
Expand Down Expand Up @@ -851,11 +827,7 @@ mod tests {
let anvil = launch_anvil();
let client = StateClient::new(anvil.endpoint_url());

let limits: Limits = Limits {
max_commitments_per_slot: NonZero::new(10).unwrap(),
max_committed_gas_per_slot: NonZero::new(10_000_000).unwrap(),
};
let mut state = ExecutionState::new(client.clone(), limits).await?;
let mut state = ExecutionState::new(client.clone(), Limits::default()).await?;

let sender = anvil.addresses().first().unwrap();
let sender_pk = anvil.keys().first().unwrap();
Expand Down

0 comments on commit 75f4dfe

Please sign in to comment.