Skip to content

Commit 404ef4a

Browse files
authored
chore: use ic-bn-lib in PocketIC HTTP gateway (#3028)
This PR uses the proxy functionality from `ic-bn-lib` to proxy `/api/v2` and `/api/v3` requests in the PocketIC HTTP gateway instead of reimplementing the proxy functionality in the PocketIC HTTP gateway.
1 parent 1c28ba9 commit 404ef4a

File tree

5 files changed

+57
-188
lines changed

5 files changed

+57
-188
lines changed

Cargo.lock

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rs/pocket_ic_server/BUILD.bazel

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,13 @@ LIB_DEPENDENCIES = [
6161
"@crate_index//:hyper",
6262
"@crate_index//:hyper-util",
6363
"@crate_index//:ic-agent",
64+
"@crate_index//:ic-bn-lib",
6465
"@crate_index//:ic-cdk",
6566
"@crate_index//:ic-http-gateway",
6667
"@crate_index//:ic-utils",
6768
"@crate_index//:itertools",
6869
"@crate_index//:rand",
70+
"@crate_index//:reqwest",
6971
"@crate_index//:serde",
7072
"@crate_index//:serde_cbor",
7173
"@crate_index//:serde_json",

rs/pocket_ic_server/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ http-body-util = { workspace = true }
2727
hyper = { workspace = true }
2828
hyper-util = { workspace = true }
2929
ic-agent = { workspace = true }
30+
ic-bn-lib = { workspace = true }
3031
ic-boundary = { path = "../boundary_node/ic_boundary" }
3132
ic-btc-adapter = { path = "../bitcoin/adapter" }
3233
ic-canister-sandbox-backend-lib = { path = "../canister_sandbox" }
@@ -65,6 +66,7 @@ ic-validator-ingress-message = { path = "../validator/ingress_message" }
6566
itertools = { workspace = true }
6667
pocket-ic = { path = "../../packages/pocket-ic" }
6768
rand = { workspace = true }
69+
reqwest = { workspace = true }
6870
serde = { workspace = true }
6971
serde_cbor = { workspace = true }
7072
serde_json = { workspace = true }

0 commit comments

Comments
 (0)