Files
pezkuwi-subxt/cumulus/parachains/runtimes/assets/test-utils/Cargo.toml
T
Muharem 2cb39f8dc9 XCM WeightTrader: Swap Fee Asset for Native Asset (#1845)
Implements an XCM executor `WeightTrader`, facilitating fee payments in
any asset that can be exchanged for a native asset.

A few constraints need to be observed:
- `buy_weight` and `refund` operations must be atomic, as another weight
trader implementation might be attempted in case of failure.
- swap credit must be utilized since there isn’t an account to which an
asset of some class can be deposited with a guarantee to meet the
existential deposit requirement. Also, operating with credits enhances
the efficiency of the weight trader -
https://github.com/paritytech/polkadot-sdk/pull/1677

related PRs:
- (depends) https://github.com/paritytech/polkadot-sdk/pull/2031
- (depends) https://github.com/paritytech/polkadot-sdk/pull/1677
- (caused) https://github.com/paritytech/polkadot-sdk/pull/1847
- (caused) https://github.com/paritytech/polkadot-sdk/pull/1876

// DONE: impl `OnUnbalanced` for a `fungible/s` credit
// DONE: make the trader free from a concept of a native currency and
drop few fallible conversions. related issue -
https://github.com/paritytech/polkadot-sdk/issues/1842
// DONE: tests

---------

Co-authored-by: joe petrowski <25483142+joepetrowski@users.noreply.github.com>
Co-authored-by: Liam Aharon <liam.aharon@hotmail.com>
2024-01-16 07:34:48 +00:00

88 lines
4.0 KiB
TOML

[package]
name = "asset-test-utils"
version = "1.0.0"
authors.workspace = true
edition.workspace = true
description = "Test utils for Asset Hub runtimes."
license = "Apache-2.0"
[lints]
workspace = true
[dependencies]
codec = { package = "parity-scale-codec", version = "3.0.0", default-features = false, features = ["derive", "max-encoded-len"] }
# Substrate
frame-support = { path = "../../../../../substrate/frame/support", default-features = false }
frame-system = { path = "../../../../../substrate/frame/system", default-features = false }
pallet-assets = { path = "../../../../../substrate/frame/assets", default-features = false }
pallet-asset-conversion = { path = "../../../../../substrate/frame/asset-conversion", default-features = false }
pallet-balances = { path = "../../../../../substrate/frame/balances", default-features = false }
pallet-session = { path = "../../../../../substrate/frame/session", default-features = false }
sp-consensus-aura = { path = "../../../../../substrate/primitives/consensus/aura", default-features = false }
sp-io = { path = "../../../../../substrate/primitives/io", default-features = false }
sp-runtime = { path = "../../../../../substrate/primitives/runtime", default-features = false }
sp-std = { path = "../../../../../substrate/primitives/std", default-features = false }
sp-core = { path = "../../../../../substrate/primitives/core", default-features = false }
# Cumulus
cumulus-pallet-parachain-system = { path = "../../../../pallets/parachain-system", default-features = false, features = ["parameterized-consensus-hook"] }
cumulus-pallet-xcmp-queue = { path = "../../../../pallets/xcmp-queue", default-features = false }
pallet-collator-selection = { path = "../../../../pallets/collator-selection", default-features = false }
parachains-common = { path = "../../../common", default-features = false }
assets-common = { path = "../common", default-features = false }
cumulus-primitives-core = { path = "../../../../primitives/core", default-features = false }
cumulus-primitives-parachain-inherent = { path = "../../../../primitives/parachain-inherent", default-features = false }
cumulus-test-relay-sproof-builder = { path = "../../../../test/relay-sproof-builder", default-features = false }
parachain-info = { package = "staging-parachain-info", path = "../../../pallets/parachain-info", default-features = false }
parachains-runtimes-test-utils = { path = "../../test-utils", default-features = false }
# Polkadot
xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false }
xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false }
xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false }
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false }
polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false }
# Bridges
pallet-xcm-bridge-hub-router = { path = "../../../../../bridges/modules/xcm-bridge-hub-router", default-features = false }
[dev-dependencies]
hex-literal = "0.4.1"
[build-dependencies]
substrate-wasm-builder = { path = "../../../../../substrate/utils/wasm-builder" }
[features]
default = ["std"]
std = [
"assets-common/std",
"codec/std",
"cumulus-pallet-parachain-system/std",
"cumulus-pallet-xcmp-queue/std",
"cumulus-primitives-core/std",
"cumulus-primitives-parachain-inherent/std",
"cumulus-test-relay-sproof-builder/std",
"frame-support/std",
"frame-system/std",
"pallet-asset-conversion/std",
"pallet-assets/std",
"pallet-balances/std",
"pallet-collator-selection/std",
"pallet-session/std",
"pallet-xcm-bridge-hub-router/std",
"pallet-xcm/std",
"parachain-info/std",
"parachains-common/std",
"parachains-runtimes-test-utils/std",
"polkadot-parachain-primitives/std",
"sp-consensus-aura/std",
"sp-core/std",
"sp-io/std",
"sp-runtime/std",
"sp-std/std",
"xcm-builder/std",
"xcm-executor/std",
"xcm/std",
]