Skip to content

Commit

Permalink
chore: mark rpc state reader config create for testing for cfg (#141)
Browse files Browse the repository at this point in the history
  • Loading branch information
ArniStarkware authored May 19, 2024
1 parent e67e201 commit 5befb75
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions crates/gateway/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ license.workspace = true
[lints]
workspace = true

[features]
testing = []

[dependencies]
axum.workspace = true
blockifier.workspace = true
Expand Down
1 change: 1 addition & 0 deletions crates/gateway/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ pub struct RpcStateReaderConfig {
pub json_rpc_version: String,
}

#[cfg(any(feature = "testing", test))]
impl RpcStateReaderConfig {
pub fn create_for_testing() -> Self {
Self { url: "http://localhost:8080".to_string(), json_rpc_version: "2.0".to_string() }
Expand Down

0 comments on commit 5befb75

Please sign in to comment.