Skip to content

Commit

Permalink
Merge branch 'master' into cl/runtime-metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
xermicus committed Nov 2, 2022
2 parents bd2f379 + 4825d0b commit c658c46
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 15 deletions.
12 changes: 5 additions & 7 deletions crates/e2e/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,15 @@ use sp_runtime::traits::{
Verify,
};
use subxt::{
blocks::ExtrinsicEvents,
ext::bitvec::macros::internal::funty::Fundamental,
metadata::DecodeStaticType,
storage::address::{
StorageHasher,
StorageMapKey,
Yes,
},
tx::{
ExtrinsicParams,
TxEvents,
},
tx::ExtrinsicParams,
};

/// An encoded `#[ink(message)]`.
Expand Down Expand Up @@ -83,7 +81,7 @@ pub struct InstantiationResult<C: subxt::Config, E: Environment> {
/// if there were any.
pub dry_run: ContractInstantiateResult<C::AccountId, E::Balance>,
/// Events that happened with the contract instantiation.
pub events: TxEvents<C>,
pub events: ExtrinsicEvents<C>,
}

/// Result of a contract upload.
Expand All @@ -94,7 +92,7 @@ pub struct UploadResult<C: subxt::Config, E: Environment> {
/// if there were any.
pub dry_run: CodeUploadResult<C::Hash, E::Balance>,
/// Events that happened with the contract instantiation.
pub events: TxEvents<C>,
pub events: ExtrinsicEvents<C>,
}

/// We implement a custom `Debug` here, to avoid requiring the trait
Expand Down Expand Up @@ -137,7 +135,7 @@ pub struct CallResult<C: subxt::Config, E: Environment, V> {
/// if there were any.
pub dry_run: ContractExecResult<E::Balance>,
/// Events that happened with the contract instantiation.
pub events: TxEvents<C>,
pub events: ExtrinsicEvents<C>,
/// Contains the return value of the called function.
///
/// This field contains the decoded `data` from the dry-run,
Expand Down
1 change: 0 additions & 1 deletion crates/e2e/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ impl subxt::Config for SubstrateConfig {
type Header =
sp_runtime::generic::Header<Self::BlockNumber, sp_runtime::traits::BlakeTwo256>;
type Signature = sp_runtime::MultiSignature;
type Extrinsic = sp_runtime::OpaqueExtrinsic;
type ExtrinsicParams = subxt::tx::SubstrateExtrinsicParams<Self>;
}

Expand Down
12 changes: 5 additions & 7 deletions crates/e2e/src/xts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,8 @@ use sp_core::{
H256,
};
use subxt::{
tx::{
ExtrinsicParams,
TxEvents,
},
blocks::ExtrinsicEvents,
tx::ExtrinsicParams,
OnlineClient,
};

Expand Down Expand Up @@ -228,7 +226,7 @@ where
data: Vec<u8>,
salt: Vec<u8>,
signer: &Signer<C>,
) -> TxEvents<C> {
) -> ExtrinsicEvents<C> {
let call = subxt::tx::StaticTxPayload::new(
"Contracts",
"instantiate_with_code",
Expand Down Expand Up @@ -306,7 +304,7 @@ where
signer: &Signer<C>,
code: Vec<u8>,
storage_deposit_limit: Option<E::Balance>,
) -> TxEvents<C> {
) -> ExtrinsicEvents<C> {
let call = subxt::tx::StaticTxPayload::new(
"Contracts",
"upload_code",
Expand Down Expand Up @@ -387,7 +385,7 @@ where
storage_deposit_limit: Option<E::Balance>,
data: Vec<u8>,
signer: &Signer<C>,
) -> TxEvents<C> {
) -> ExtrinsicEvents<C> {
let call = subxt::tx::StaticTxPayload::new(
"Contracts",
"call",
Expand Down

0 comments on commit c658c46

Please sign in to comment.