File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ use crate::{
44} ;
55use alloy_primitives:: Address ;
66use foundry_common:: fmt:: UIfmt ;
7+ use itertools:: Itertools ;
78
89/// Represents possible diagnostic cases on revert
910#[ derive( Debug , Clone ) ]
@@ -33,8 +34,11 @@ impl RevertDiagnostic {
3334 let contract_label = get_label ( & b160_to_h160 ( * contract) ) ;
3435
3536 format ! (
36- r#"Contract {contract_label} does not exist on active fork with id `{active}`
37- But exists on non active forks: `{available_on:?}`"#
37+ r#"Contract {} does not exist on active fork with id `{}`
38+ But exists on non active forks: `[{}]`"# ,
39+ contract_label,
40+ active,
41+ available_on. iter( ) . format( ", " )
3842 )
3943 }
4044 RevertDiagnostic :: ContractDoesNotExist { contract, persistent, .. } => {
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ async fn test_cheats_fork_revert() {
2828 for ( _, result) in test_results {
2929 assert_eq ! (
3030 result. reason. unwrap( ) ,
31- "Contract 0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f does not exist on active fork with id `1`\n But exists on non active forks: `[0x0_U256 ]`"
31+ "Contract 0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f does not exist on active fork with id `1`\n But exists on non active forks: `[0 ]`"
3232 ) ;
3333 }
3434 }
You can’t perform that action at this time.
0 commit comments