diff --git a/crates/cast/bin/opts.rs b/crates/cast/bin/opts.rs index b763821fa06d..dcd557d310fa 100644 --- a/crates/cast/bin/opts.rs +++ b/crates/cast/bin/opts.rs @@ -883,6 +883,35 @@ mod tests { use cast::SimpleCast; use ethers_core::types::BlockNumber; + #[test] + fn parse_proof_slot() { + let args: Opts = Opts::parse_from([ + "foundry-cli", + "proof", + "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2", + "0", + "1", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x1", + "0x01", + ]); + match args.sub { + Subcommands::Proof { slots, .. } => { + assert_eq!( + slots, + vec![ + B256::ZERO, + U256::from(1).into(), + B256::ZERO, + U256::from(1).into(), + U256::from(1).into() + ] + ); + } + _ => unreachable!(), + }; + } + #[test] fn parse_call_data() { let args: Opts = Opts::parse_from([