Skip to content

Commit

Permalink
Fix Holesky RPC provider url (#184)
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasArrachea authored Dec 19, 2024
1 parent 070d76d commit 305a7ad
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
23 changes: 10 additions & 13 deletions crates/chainio/clients/avsregistry/src/reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -634,23 +634,18 @@ impl AvsRegistryChainReader {
mod tests {
use super::*;
use eigen_logging::get_test_logger;
use eigen_testing_utils::m2_holesky_constants::{
HOLESKY_RPC_PROVIDER, OPERATOR_STATE_RETRIEVER, REGISTRY_COORDINATOR,
};
use hex::FromHex;
use std::str::FromStr;
const HOLESKY_REGISTRY_COORDINATOR: &str = "0x53012C69A189cfA2D9d29eb6F19B32e0A2EA3490";
const HOLESKY_OPERATOR_STATE_RETRIEVER: &str = "0xB4baAfee917fb4449f5ec64804217bccE9f46C67";

async fn build_avs_registry_chain_reader() -> AvsRegistryChainReader {
let holesky_registry_coordinator =
Address::from_str(HOLESKY_REGISTRY_COORDINATOR).expect("failed to parse address");
let holesky_operator_state_retriever =
Address::from_str(HOLESKY_OPERATOR_STATE_RETRIEVER).expect("failed to parse address");

let holesky_provider = "https://ethereum-holesky.blockpi.network/v1/rpc/public";
AvsRegistryChainReader::new(
get_test_logger(),
holesky_registry_coordinator,
holesky_operator_state_retriever,
holesky_provider.to_string(),
REGISTRY_COORDINATOR,
OPERATOR_STATE_RETRIEVER,
HOLESKY_RPC_PROVIDER.to_string(),
)
.await
.unwrap()
Expand Down Expand Up @@ -734,9 +729,11 @@ mod tests {
#[tokio::test]
async fn test_is_operator_registered() {
let avs_reader = build_avs_registry_chain_reader().await;
let address = Address::from_str(HOLESKY_REGISTRY_COORDINATOR).unwrap();

let is_registered = avs_reader.is_operator_registered(address).await.unwrap();
let is_registered = avs_reader
.is_operator_registered(REGISTRY_COORDINATOR)
.await
.unwrap();
assert!(!is_registered);
}

Expand Down
3 changes: 3 additions & 0 deletions testing/testing-utils/src/m2_holesky_constants.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
use alloy_primitives::{address, Address};

/// Holesky rpc provider
pub const HOLESKY_RPC_PROVIDER: &str = "https://ethereum-holesky-rpc.publicnode.com";

/// https://holesky.etherscan.io/address/0xA44151489861Fe9e3055d95adC98FbD462B948e7
pub const DELEGATION_MANAGER_ADDRESS: Address =
address!("A44151489861Fe9e3055d95adC98FbD462B948e7");
Expand Down

0 comments on commit 305a7ad

Please sign in to comment.