-
Notifications
You must be signed in to change notification settings - Fork 11.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[bridge] refactor test utils #17288
[bridge] refactor test utils #17288
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
3 Ignored Deployments
|
} | ||
} | ||
|
||
impl BridgeTestClusterBuilder { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks!
feel free to go in or address comments if you care.
Not a big deal either way
} | ||
|
||
pub fn sui_client(&self) -> SuiClient { | ||
self.test_cluster.fullnode_handle.sui_client.clone() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suppose we could clone
on the caller side and return a reference?
} | ||
|
||
pub fn bridge_authority_key(&self, index: usize) -> BridgeAuthorityKeyPair { | ||
self.test_cluster.bridge_authority_keys.as_ref().unwrap()[index].copy() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
copy
on the client?
} | ||
|
||
pub fn sui_rpc_url(&self) -> String { | ||
self.test_cluster.fullnode_handle.rpc_url.clone() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clone
on the client?
} | ||
|
||
pub fn eth_rpc_url(&self) -> String { | ||
self.eth_environment.rpc_url.clone() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clone
on the client?
## Description This PR: 1. refactors e2e test utils by introducing `BridgeTestClusterBuilder` and `BridgeTestCluster` 2. enables the ability to drop spawned BridgeNodes, and restart them (not in this PR, but this PR makes it easy to do) 3. speeds up the setup by doing things in parallel. This probably cuts at least 20 seconds for each test. ## Test plan existing tests --- ## Release notes Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK:
## Description This PR: 1. refactors e2e test utils by introducing `BridgeTestClusterBuilder` and `BridgeTestCluster` 2. enables the ability to drop spawned BridgeNodes, and restart them (not in this PR, but this PR makes it easy to do) 3. speeds up the setup by doing things in parallel. This probably cuts at least 20 seconds for each test. ## Test plan existing tests --- ## Release notes Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK:
## Description This PR: 1. refactors e2e test utils by introducing `BridgeTestClusterBuilder` and `BridgeTestCluster` 2. enables the ability to drop spawned BridgeNodes, and restart them (not in this PR, but this PR makes it easy to do) 3. speeds up the setup by doing things in parallel. This probably cuts at least 20 seconds for each test. ## Test plan existing tests --- ## Release notes Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK:
## Description This PR: 1. refactors e2e test utils by introducing `BridgeTestClusterBuilder` and `BridgeTestCluster` 2. enables the ability to drop spawned BridgeNodes, and restart them (not in this PR, but this PR makes it easy to do) 3. speeds up the setup by doing things in parallel. This probably cuts at least 20 seconds for each test. ## Test plan existing tests --- ## Release notes Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK:
## Description This PR: 1. refactors e2e test utils by introducing `BridgeTestClusterBuilder` and `BridgeTestCluster` 2. enables the ability to drop spawned BridgeNodes, and restart them (not in this PR, but this PR makes it easy to do) 3. speeds up the setup by doing things in parallel. This probably cuts at least 20 seconds for each test. ## Test plan existing tests --- ## Release notes Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK:
## Description This PR: 1. refactors e2e test utils by introducing `BridgeTestClusterBuilder` and `BridgeTestCluster` 2. enables the ability to drop spawned BridgeNodes, and restart them (not in this PR, but this PR makes it easy to do) 3. speeds up the setup by doing things in parallel. This probably cuts at least 20 seconds for each test. ## Test plan existing tests --- ## Release notes Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK:
Description
This PR:
BridgeTestClusterBuilder
andBridgeTestCluster
Test plan
existing tests
Release notes
Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required.
For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates.