From 08c7027a9d5568fa33cb1ede32ca40bd17acc95e Mon Sep 17 00:00:00 2001 From: ilya Date: Tue, 5 Mar 2024 21:03:25 +0000 Subject: [PATCH] Network fee --- crates/driver/src/tests/cases/protocol_fees.rs | 8 ++++---- crates/driver/src/tests/setup/mod.rs | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/driver/src/tests/cases/protocol_fees.rs b/crates/driver/src/tests/cases/protocol_fees.rs index c66ede2a78..0be7607576 100644 --- a/crates/driver/src/tests/cases/protocol_fees.rs +++ b/crates/driver/src/tests/cases/protocol_fees.rs @@ -198,7 +198,7 @@ async fn price_improvement_fee_buy_out_of_market_order() { quote: PriceImprovementQuote { sell_amount: 50000000000000000000u128.into(), buy_amount: 35000000000000000000u128.into(), - fee: 1000000000000000000u128.into(), + network_fee: 1000000000000000000u128.into(), }, }; let order_sell_amount = 50000000000000000000u128.into(); @@ -227,7 +227,7 @@ async fn price_improvement_fee_sell_out_of_market_order() { quote: PriceImprovementQuote { sell_amount: 50000000000000000000u128.into(), buy_amount: 35000000000000000000u128.into(), - fee: 1000000000000000000u128.into(), + network_fee: 1000000000000000000u128.into(), }, }; let order_sell_amount = 50000000000000000000u128.into(); @@ -257,7 +257,7 @@ async fn price_improvement_fee_buy_in_market_order() { quote: PriceImprovementQuote { sell_amount: 50000000000000000000u128.into(), buy_amount: 40000000000000000000u128.into(), - fee: 1000000000000000000u128.into(), + network_fee: 1000000000000000000u128.into(), }, }; let order_sell_amount = 50000000000000000000u128.into(); @@ -286,7 +286,7 @@ async fn price_improvement_fee_sell_in_market_order() { quote: PriceImprovementQuote { sell_amount: 50000000000000000000u128.into(), buy_amount: 40000000000000000000u128.into(), - fee: 1000000000000000000u128.into(), + network_fee: 1000000000000000000u128.into(), }, }; let order_sell_amount: eth::U256 = 50000000000000000000u128.into(); diff --git a/crates/driver/src/tests/setup/mod.rs b/crates/driver/src/tests/setup/mod.rs index 3e203406f5..80b44ccf67 100644 --- a/crates/driver/src/tests/setup/mod.rs +++ b/crates/driver/src/tests/setup/mod.rs @@ -78,7 +78,7 @@ pub enum Score { pub struct PriceImprovementQuote { pub buy_amount: eth::U256, pub sell_amount: eth::U256, - pub fee: eth::U256, + pub network_fee: eth::U256, } #[serde_as] @@ -120,7 +120,7 @@ impl FeePolicy { "quote": { "sellAmount": quote.sell_amount, "buyAmount": quote.buy_amount, - "fee": quote.fee, + "fee": quote.network_fee, } } }),