The buy and sell methods have added the priority_fee parameter, which can control the priority fee for each transaction

This commit is contained in:
wei
2025-09-02 09:43:53 +08:00
parent 7aa676781c
commit 6f953ffa0d
13 changed files with 107 additions and 9 deletions
+17
View File
@@ -120,6 +120,7 @@ async fn test_middleware() -> AnyResult<()> {
Box::new(PumpSwapParams::from_pool_address_by_rpc(&client.rpc, &pool_address).await?),
None,
true,
None,
)
.await?;
Ok(())
@@ -147,6 +148,7 @@ async fn test_pumpfun_copy_trade_with_grpc(trade_info: PumpFunTradeEvent) -> Any
Box::new(PumpFunParams::from_trade(&trade_info, None)),
None,
true,
None,
)
.await?;
@@ -165,6 +167,7 @@ async fn test_pumpfun_copy_trade_with_grpc(trade_info: PumpFunTradeEvent) -> Any
Box::new(PumpFunParams::from_trade(&trade_info, None)),
None,
true,
None,
)
.await?;
@@ -197,6 +200,7 @@ async fn test_pumpfun_sniper_trade_with_shreds(trade_info: PumpFunTradeEvent) ->
Box::new(PumpFunParams::from_trade(&trade_info, None)),
None,
true,
None,
)
.await?;
@@ -215,6 +219,7 @@ async fn test_pumpfun_sniper_trade_with_shreds(trade_info: PumpFunTradeEvent) ->
Box::new(PumpFunParams::from_trade(&trade_info, None)),
None,
true,
None,
)
.await?;
@@ -245,6 +250,7 @@ async fn test_pumpswap() -> AnyResult<()> {
Box::new(PumpSwapParams::from_pool_address_by_rpc(&client.rpc, &pool_address).await?),
None,
true,
None,
)
.await?;
@@ -264,6 +270,7 @@ async fn test_pumpswap() -> AnyResult<()> {
Box::new(PumpSwapParams::from_pool_address_by_rpc(&client.rpc, &pool_address).await?),
None,
true,
None,
)
.await?;
@@ -292,6 +299,7 @@ async fn test_bonk_copy_trade_with_grpc(trade_info: BonkTradeEvent) -> AnyResult
Box::new(BonkParams::from_trade(trade_info.clone())),
None,
true,
None,
)
.await?;
@@ -310,6 +318,7 @@ async fn test_bonk_copy_trade_with_grpc(trade_info: BonkTradeEvent) -> AnyResult
Box::new(BonkParams::from_trade(trade_info)),
None,
true,
None,
)
.await?;
@@ -342,6 +351,7 @@ async fn test_bonk_sniper_trade_with_shreds(trade_info: BonkTradeEvent) -> AnyRe
Box::new(BonkParams::from_dev_trade(trade_info.clone())),
None,
true,
None,
)
.await?;
@@ -360,6 +370,7 @@ async fn test_bonk_sniper_trade_with_shreds(trade_info: BonkTradeEvent) -> AnyRe
Box::new(BonkParams::from_dev_trade(trade_info)),
None,
true,
None,
)
.await?;
@@ -389,6 +400,7 @@ async fn test_bonk() -> Result<(), Box<dyn std::error::Error>> {
Box::new(BonkParams::from_mint_by_rpc(&client.rpc, &mint_pubkey).await?),
None,
true,
None,
)
.await?;
@@ -408,6 +420,7 @@ async fn test_bonk() -> Result<(), Box<dyn std::error::Error>> {
Box::new(BonkParams::from_mint_by_rpc(&client.rpc, &mint_pubkey).await?),
None,
true,
None,
)
.await?;
@@ -439,6 +452,7 @@ async fn test_raydium_cpmm() -> Result<(), Box<dyn std::error::Error>> {
),
None,
true,
None,
)
.await?;
@@ -460,6 +474,7 @@ async fn test_raydium_cpmm() -> Result<(), Box<dyn std::error::Error>> {
),
None,
true,
None,
)
.await?;
@@ -489,6 +504,7 @@ async fn test_raydium_amm_v4() -> Result<(), Box<dyn std::error::Error>> {
Box::new(RaydiumAmmV4Params::from_amm_address_by_rpc(&client.rpc, amm_address).await?),
None,
true,
None,
)
.await?;
@@ -508,6 +524,7 @@ async fn test_raydium_amm_v4() -> Result<(), Box<dyn std::error::Error>> {
Box::new(RaydiumAmmV4Params::from_amm_address_by_rpc(&client.rpc, amm_address).await?),
None,
true,
None,
)
.await?;