@@ -8,6 +8,7 @@ use alloy_provider::Provider;
8
8
use alloy_rpc_types:: TransactionRequest ;
9
9
use alloy_serde:: WithOtherFields ;
10
10
use anvil:: { NodeConfig , spawn} ;
11
+ use foundry_evm_networks:: NetworkConfigs ;
11
12
use op_alloy_consensus:: TxDeposit ;
12
13
use op_alloy_rpc_types:: OpTransactionFields ;
13
14
@@ -47,7 +48,8 @@ async fn test_deposits_not_supported_if_optimism_disabled() {
47
48
#[ tokio:: test( flavor = "multi_thread" ) ]
48
49
async fn test_send_value_deposit_transaction ( ) {
49
50
// enable the Optimism flag
50
- let ( api, handle) = spawn ( NodeConfig :: test ( ) . with_optimism ( true ) ) . await ;
51
+ let ( api, handle) =
52
+ spawn ( NodeConfig :: test ( ) . with_networks ( NetworkConfigs :: with_optimism ( ) ) ) . await ;
51
53
52
54
let accounts: Vec < _ > = handle. dev_wallets ( ) . collect ( ) ;
53
55
let signer: EthereumWallet = accounts[ 0 ] . clone ( ) . into ( ) ;
@@ -94,7 +96,8 @@ async fn test_send_value_deposit_transaction() {
94
96
#[ tokio:: test( flavor = "multi_thread" ) ]
95
97
async fn test_send_value_raw_deposit_transaction ( ) {
96
98
// enable the Optimism flag
97
- let ( api, handle) = spawn ( NodeConfig :: test ( ) . with_optimism ( true ) ) . await ;
99
+ let ( api, handle) =
100
+ spawn ( NodeConfig :: test ( ) . with_networks ( NetworkConfigs :: with_optimism ( ) ) ) . await ;
98
101
99
102
let accounts: Vec < _ > = handle. dev_wallets ( ) . collect ( ) ;
100
103
let signer: EthereumWallet = accounts[ 0 ] . clone ( ) . into ( ) ;
@@ -150,7 +153,8 @@ async fn test_send_value_raw_deposit_transaction() {
150
153
#[ tokio:: test( flavor = "multi_thread" ) ]
151
154
async fn test_deposit_transaction_hash_matches_sepolia ( ) {
152
155
// enable the Optimism flag
153
- let ( _api, handle) = spawn ( NodeConfig :: test ( ) . with_optimism ( true ) ) . await ;
156
+ let ( _api, handle) =
157
+ spawn ( NodeConfig :: test ( ) . with_networks ( NetworkConfigs :: with_optimism ( ) ) ) . await ;
154
158
155
159
let accounts: Vec < _ > = handle. dev_wallets ( ) . collect ( ) ;
156
160
let signer: EthereumWallet = accounts[ 0 ] . clone ( ) . into ( ) ;
@@ -181,7 +185,8 @@ async fn test_deposit_transaction_hash_matches_sepolia() {
181
185
#[ tokio:: test( flavor = "multi_thread" ) ]
182
186
async fn test_deposit_tx_checks_sufficient_funds_after_applying_deposited_value ( ) {
183
187
// enable the Optimism flag
184
- let ( _api, handle) = spawn ( NodeConfig :: test ( ) . with_optimism ( true ) ) . await ;
188
+ let ( _api, handle) =
189
+ spawn ( NodeConfig :: test ( ) . with_networks ( NetworkConfigs :: with_optimism ( ) ) ) . await ;
185
190
186
191
let provider = http_provider ( & handle. http_endpoint ( ) ) ;
187
192
0 commit comments