@@ -22,19 +22,19 @@ pub type NetworkError = String;
2222
2323#[ derive( Error , Debug ) ]
2424pub enum MigrateError {
25- #[ error( "Migration failed with error : {1}" ) ]
25+ #[ error( "Migration failed for mint {0} : {1}" ) ]
2626 MigrationFailed ( MintAddress , NetworkError ) ,
2727}
2828
2929#[ derive( Error , Debug ) ]
3030pub enum UpdateError {
31- #[ error( "Action failed with error : {1}" ) ]
31+ #[ error( "Action failed for mint {0} : {1}" ) ]
3232 UpdateFailed ( MintAddress , NetworkError ) ,
3333}
3434
3535#[ derive( Error , Debug ) ]
3636pub enum ActionError {
37- #[ error( "Action failed with error : {1}" ) ]
37+ #[ error( "Action failed for mint {0} : {1}" ) ]
3838 ActionFailed ( MintAddress , NetworkError ) ,
3939}
4040
@@ -95,7 +95,7 @@ mod tests {
9595 ) ;
9696 assert_eq ! (
9797 err. to_string( ) ,
98- "Migration failed with error : connection refused"
98+ "Migration failed for mint AbcDef123 : connection refused"
9999 ) ;
100100 }
101101
@@ -104,15 +104,15 @@ mod tests {
104104 #[ test]
105105 fn update_error_display ( ) {
106106 let err = UpdateError :: UpdateFailed ( "mint123" . to_string ( ) , "tx failed" . to_string ( ) ) ;
107- assert_eq ! ( err. to_string( ) , "Action failed with error : tx failed" ) ;
107+ assert_eq ! ( err. to_string( ) , "Action failed for mint mint123 : tx failed" ) ;
108108 }
109109
110110 // ActionError tests
111111
112112 #[ test]
113113 fn action_error_display ( ) {
114114 let err = ActionError :: ActionFailed ( "mint456" . to_string ( ) , "timeout" . to_string ( ) ) ;
115- assert_eq ! ( err. to_string( ) , "Action failed with error : timeout" ) ;
115+ assert_eq ! ( err. to_string( ) , "Action failed for mint mint456 : timeout" ) ;
116116 }
117117
118118 // SolConfigError tests
0 commit comments