Skip to content

Commit

Permalink
Adds transfer token user fee (#987)
Browse files Browse the repository at this point in the history
* starts with adding snowbridge conf

* updates fee

* fix expected fee

---------

Co-authored-by: claravanstaden <Cats 4 life!>
  • Loading branch information
claravanstaden authored Nov 6, 2023
1 parent 08c5817 commit c9196e1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion parachain/pallets/outbound-queue/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -249,9 +249,11 @@ pub mod pallet {

#[pallet::type_value]
pub fn DefaultFeeConfig() -> FeeConfigRecord {
// When the FeeConfigRecord is updated, so should this fee constant on asset hub:
// polkadot-sdk/cumulus/parachains/common/src/snowbridge_config.rs
FeeConfigRecord {
exchange_rate: FixedU128::saturating_from_rational(1, 400),
fee_per_gas: 30 * GWEI,
fee_per_gas: 20 * GWEI,
#[allow(clippy::identity_op)]
reward: 1 * METH,
}
Expand Down
2 changes: 1 addition & 1 deletion parachain/pallets/outbound-queue/src/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ fn calculate_fees() {
new_tester().execute_with(|| {
let command = mock_message(1000).command;
let fee = OutboundQueue::calculate_fee(&command);
assert_eq!(fee.remote, 31000000000);
assert_eq!(fee.remote, 22000000000);

println!("Total fee: {}", fee.total())
});
Expand Down

0 comments on commit c9196e1

Please sign in to comment.