Expand description
Various utilities to decode test results.
Re-exportsΒ§
use crate::abi::Vm;πuse crate::abi::console;πuse alloy_dyn_abi::JsonAbiExt;πuse alloy_json_abi::Error;πuse alloy_json_abi::JsonAbi;πuse alloy_primitives::Log;πuse alloy_primitives::Selector;πuse alloy_primitives::hex;πuse alloy_primitives::hex;πuse alloy_primitives::map::HashMap;πuse alloy_sol_types::ContractError::Revert;πuse alloy_sol_types::RevertReason;πuse alloy_sol_types::RevertReason::ContractError;πuse alloy_sol_types::SolEventInterface;πuse alloy_sol_types::SolInterface;πuse alloy_sol_types::SolValue;πuse foundry_common::SELECTOR_LEN;πuse itertools::Itertools;πuse revm::interpreter::InstructionResult;πuse std::fmt;πuse std::sync::OnceLock;π
StructsΒ§
- Revert
Decoder - Decodes revert data.
- Skip
Reason - A skip reason.
ConstantsΒ§
- ASSERTION_
FAILED_ PREFIX - Prefix used by Foundry assertion helpers in user-visible failure messages.
- EMPTY_
REVERT_ DATA - Stable user-facing fallback for empty revert payloads.
FunctionsΒ§
- decode_
as_ πnon_ empty_ string - Helper function that decodes provided error as an ABI encoded or an ASCII string (if not empty).
- decode_
console_ log - Decode a single log.
- decode_
console_ logs - Decode a set of logs, only returning logs from DSTest logging events and Hardhatβs
console.log - trimmed_
hex π