Skip to content
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

testing: Prepare light client testing with substrate binary and add subxt-test macro #1507

Merged
merged 44 commits into from
Apr 8, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
34e9222
testing: Add long running light client flag and cfg aliases
lexnv Feb 29, 2024
518aa8e
testing: Expose clients depending on feature flags
lexnv Feb 29, 2024
ea6f3cc
subxt: Use unstable backend for light client
lexnv Feb 29, 2024
ca36ef6
testing: Disable flaky lightclient tests
lexnv Feb 29, 2024
8fe7e86
ci: Add long runnnig step
lexnv Feb 29, 2024
593fbeb
Revert "subxt: Use unstable backend for light client"
lexnv Feb 29, 2024
1fc1bb4
ci: Long running tests for 60 mins
lexnv Feb 29, 2024
ca60c31
ci: Use 16 cores for light-client testing
lexnv Feb 29, 2024
3c58c5e
ci: Isolate light-client testing to save CI minutes
lexnv Feb 29, 2024
0248343
testing: Retry on Tx::Dropped for lightclinet only
lexnv Mar 1, 2024
8400a0e
testing: Wait for more blocks for the lightclient init
lexnv Mar 1, 2024
d671664
subxt: Use unstable backend for light client
lexnv Feb 29, 2024
318ba5c
testing: Disable legacy RPC tests
lexnv Mar 1, 2024
1a6f1af
testing: Disable sudo and contracts tests
lexnv Mar 1, 2024
332fa72
testing: Retry constructing lightclient on read-proof errors
lexnv Mar 1, 2024
88ccc54
testing: Disable tx dynamic test
lexnv Mar 1, 2024
b6c98c7
proc-macro: Timeout for tests
lexnv Mar 1, 2024
20e75bc
testing: Add timeout 800 seconds
lexnv Mar 1, 2024
c5c7972
proc-macro/tests: Adjust subxt-test proc-macro
lexnv Mar 4, 2024
d3923c8
proc-macro: Rename crate to subxt-test-proc-macro
lexnv Mar 5, 2024
1a64750
Use default subxt-proc-macro timeout
lexnv Mar 5, 2024
4c3226e
light-client: Remove println
lexnv Mar 5, 2024
fbe2a74
subxt: Remove tokio as dependency, use it only for testing
lexnv Mar 5, 2024
30073d3
testing: Chagne default timeout to 6 seconds
lexnv Mar 5, 2024
aa55cea
proc-macro: Add env timeout variable
lexnv Mar 6, 2024
09277fe
ci: Add subxt env var for controling test timeouts
lexnv Mar 6, 2024
5039f1c
tests/tx-retries: Retry on `Non node available` error
lexnv Mar 6, 2024
410aaed
Merge remote-tracking branch 'origin/master' into lenxv/light-client-…
lexnv Mar 26, 2024
d81c70c
testing: Use unstable backend for testing lightclient
lexnv Mar 26, 2024
00c4b78
testing: Remove old lightclient object
lexnv Mar 26, 2024
03da904
testing: Adjust for the new interface
lexnv Mar 26, 2024
292f971
backend/rpc: Allow older version of the initialized event
lexnv Mar 27, 2024
2bc8947
rpc/tests: Check initialized decodes correctly
lexnv Mar 28, 2024
811f70c
ci: Reset workflow
lexnv Mar 28, 2024
2bb8acb
Apply cargo fmt
lexnv Mar 28, 2024
1fdd734
Remove unused dep
lexnv Mar 28, 2024
1bc6eb9
Merge remote-tracking branch 'origin/master' into lexnv/light-client-…
lexnv Mar 28, 2024
5692703
Remove gitmerge old file
lexnv Mar 28, 2024
fd47be1
Remove unused dep
lexnv Mar 28, 2024
be4b34c
rename proc-macro to subxt-test-macro
lexnv Apr 2, 2024
7270da8
tests: Remove txretries for lightclient
lexnv Apr 3, 2024
a62ceb7
tests: Wait for 5 blocks for the lightclient full testing suite
lexnv Apr 3, 2024
7664b56
tests: Group imports
lexnv Apr 8, 2024
510578f
macro: Rename const value
lexnv Apr 8, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
testing: Remove old lightclient object
Signed-off-by: Alexandru Vasile <[email protected]>
  • Loading branch information
lexnv committed Mar 26, 2024
commit 00c4b781491f976a598fe6c9636241788428e13c
20 changes: 19 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 1 addition & 10 deletions testing/integration-tests/src/utils/context.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,8 @@

pub(crate) use crate::{node_runtime, utils::TestNodeProcess};

use subxt::SubstrateConfig;

#[cfg(lightclient)]
use subxt::client::LightClient;

#[cfg(fullclient)]
use subxt::client::OnlineClient;
use subxt::SubstrateConfig;

/// `substrate-node` should be installed on the $PATH. We fall back
/// to also checking for an older `substrate` binary.
Expand All @@ -30,12 +25,8 @@ pub type TestConfig = SubstrateConfig;

pub type TestContext = TestNodeProcess<SubstrateConfig>;

#[cfg(fullclient)]
pub type TestClient = OnlineClient<SubstrateConfig>;

#[cfg(lightclient)]
pub type TestClient = LightClient<SubstrateConfig>;

pub async fn test_context() -> TestContext {
test_context_with("alice".to_string()).await
}