File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -917,7 +917,10 @@ func TestRunReadEmailsFrom(t *testing.T) {
917
917
}
918
918
919
919
// Test that run() runs without error
920
- m .run (context .Background ())
920
+ err = m .run (context .Background ())
921
+ if err != nil {
922
+ t .Error ("Error running with readEmailsFrom flag" )
923
+ }
921
924
}
922
925
923
926
// When saveEmailsTo flag set, test that resolveAdresses() and run() run correctly
@@ -962,8 +965,11 @@ func TestRunSaveEmailsTo(t *testing.T) {
962
965
}
963
966
964
967
// Test that run() saves resolved addresses to saveEmailsTo
965
- m .run (context .Background ())
968
+ err = m .run (context .Background ())
966
969
defer os .Remove (m .saveEmailsTo )
970
+ if err != nil {
971
+ t .Error ("Error running with saveEmailsTo flag" )
972
+ }
967
973
968
974
saveFile , err := os .ReadFile (m .saveEmailsTo )
969
975
if err != nil {
@@ -1029,8 +1035,11 @@ func TestReadAndSaveBatchCase(t *testing.T) {
1029
1035
1030
1036
// Test that run() saves both a) emails extracted from readEmailsFrom and b) emails resolved
1031
1037
// by resolvedAddresses() in saveEmailsTo file
1032
- m .run (context .Background ())
1038
+ err = m .run (context .Background ())
1033
1039
defer os .Remove (m .saveEmailsTo )
1040
+ if err != nil {
1041
+ t .Error ("Error running with saveEmailsTo and readEmailsFrom flags" )
1042
+ }
1034
1043
1035
1044
saveFile , err := os .ReadFile (m .saveEmailsTo )
1036
1045
if err != nil {
You can’t perform that action at this time.
0 commit comments