mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 02:21:14 +00:00
Merge remote-tracking branch 'origin/master' into na-jsonrpsee-core-client
This commit is contained in:
+4
-4
@@ -17,7 +17,7 @@ keywords = ["parity", "substrate", "blockchain"]
|
||||
[dependencies]
|
||||
async-std = { version = "1.8.0", features = ["tokio1"] }
|
||||
futures = "0.3.9"
|
||||
jsonrpsee = { version = "0.7.0", features = ["async-client"] }
|
||||
jsonrpsee = { version = "0.8.0", features = ["async-client"] }
|
||||
log = "0.4.13"
|
||||
thiserror = "1.0.23"
|
||||
serde_json = "1"
|
||||
@@ -27,7 +27,7 @@ sp-keyring = { git = "https://github.com/paritytech/substrate.git", branch = "ma
|
||||
sc-network = { git = "https://github.com/paritytech/substrate.git", branch = "master" }
|
||||
sc-service = { git = "https://github.com/paritytech/substrate.git", branch = "master" }
|
||||
|
||||
tokio = { version = "1.10", features = ["rt-multi-thread"] }
|
||||
tokio = { version = "1.16", features = ["rt-multi-thread"] }
|
||||
|
||||
[target.'cfg(target_arch="x86_64")'.dependencies]
|
||||
sc-service = { git = "https://github.com/paritytech/substrate.git", branch = "master", default-features = false, features = [
|
||||
@@ -36,9 +36,9 @@ sc-service = { git = "https://github.com/paritytech/substrate.git", branch = "ma
|
||||
|
||||
[dev-dependencies]
|
||||
async-std = { version = "1.8.0", features = ["attributes"] }
|
||||
env_logger = "0.8.2"
|
||||
env_logger = "0.9"
|
||||
tracing-subscriber = { version = "0.3.3", features = ["env-filter"] }
|
||||
node-cli = { git = "https://github.com/paritytech/substrate.git", branch = "master", default-features = false }
|
||||
tempdir = "0.3.7"
|
||||
subxt = { path = ".." }
|
||||
subxt = { path = "../subxt" }
|
||||
test-runtime = { path = "../test-runtime" }
|
||||
|
||||
+6
-10
@@ -27,13 +27,10 @@ use sp_keyring::AccountKeyring;
|
||||
use subxt::{
|
||||
ClientBuilder,
|
||||
PairSigner,
|
||||
DefaultConfig,
|
||||
DefaultExtra
|
||||
};
|
||||
use tempdir::TempDir;
|
||||
use test_runtime::node_runtime::{
|
||||
self,
|
||||
system,
|
||||
DefaultConfig,
|
||||
};
|
||||
|
||||
#[async_std::test]
|
||||
pub async fn test_embedded_client() {
|
||||
@@ -74,12 +71,11 @@ pub async fn test_embedded_client() {
|
||||
|
||||
let ext_client = ClientBuilder::new()
|
||||
.set_client(client)
|
||||
.build::<DefaultConfig>()
|
||||
.build()
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
let api: node_runtime::RuntimeApi<DefaultConfig> =
|
||||
ext_client.clone().to_runtime_api();
|
||||
let api: test_runtime::node_runtime::RuntimeApi<DefaultConfig, DefaultExtra<_>> = ext_client.clone().to_runtime_api();
|
||||
|
||||
// verify that we can read storage
|
||||
api.storage()
|
||||
@@ -88,7 +84,7 @@ pub async fn test_embedded_client() {
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
let alice = PairSigner::<DefaultConfig, _>::new(AccountKeyring::Alice.pair());
|
||||
let alice = PairSigner::new(AccountKeyring::Alice.pair());
|
||||
let bob_address = AccountKeyring::Bob.to_account_id().into();
|
||||
|
||||
// verify that we can call dispatchable functions
|
||||
@@ -106,5 +102,5 @@ pub async fn test_embedded_client() {
|
||||
panic!("{:?}", events);
|
||||
|
||||
// verify that we receive events
|
||||
//assert!(success);
|
||||
// assert!(success);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user