mirror of
https://github.com/pezkuwichain/revive-differential-tests.git
synced 2026-05-01 15:47:57 +00:00
Add resolution logic for other matterlabs variables
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
//! The test driver handles the compilation and execution of the test cases.
|
||||
|
||||
use alloy::json_abi::JsonAbi;
|
||||
use alloy::network::TransactionBuilder;
|
||||
use alloy::network::{Ethereum, TransactionBuilder};
|
||||
use alloy::rpc::types::TransactionReceipt;
|
||||
use alloy::rpc::types::trace::geth::GethTrace;
|
||||
use alloy::{
|
||||
@@ -135,17 +135,21 @@ where
|
||||
std::any::type_name::<T>()
|
||||
);
|
||||
|
||||
let tx =
|
||||
match input.legacy_transaction(nonce, &self.deployed_contracts, &self.deployed_abis) {
|
||||
Ok(tx) => {
|
||||
tracing::debug!("Legacy transaction data: {tx:#?}");
|
||||
tx
|
||||
}
|
||||
Err(err) => {
|
||||
tracing::error!("Failed to construct legacy transaction: {err:?}");
|
||||
return Err(err);
|
||||
}
|
||||
};
|
||||
let tx = match input.legacy_transaction(
|
||||
nonce,
|
||||
&self.deployed_contracts,
|
||||
&self.deployed_abis,
|
||||
node,
|
||||
) {
|
||||
Ok(tx) => {
|
||||
tracing::debug!("Legacy transaction data: {tx:#?}");
|
||||
tx
|
||||
}
|
||||
Err(err) => {
|
||||
tracing::error!("Failed to construct legacy transaction: {err:?}");
|
||||
return Err(err);
|
||||
}
|
||||
};
|
||||
|
||||
tracing::trace!("Executing transaction for input: {input:?}");
|
||||
|
||||
@@ -231,10 +235,12 @@ where
|
||||
// automatically fill in all of the missing fields from the provider that we
|
||||
// are using.
|
||||
let code = alloy::hex::decode(&code)?;
|
||||
let tx = TransactionRequest::default()
|
||||
.nonce(nonce)
|
||||
.from(input.caller)
|
||||
.with_deploy_code(code);
|
||||
let tx = {
|
||||
let tx = TransactionRequest::default()
|
||||
.nonce(nonce)
|
||||
.from(input.caller);
|
||||
TransactionBuilder::<Ethereum>::with_deploy_code(tx, code)
|
||||
};
|
||||
|
||||
let receipt = match node.execute_transaction(tx) {
|
||||
Ok(receipt) => receipt,
|
||||
|
||||
Reference in New Issue
Block a user