public void LocateFile_ErrorMessageProvidedAndFileNoteFound_WouldShowErrorReport() { var locator = new FileLocator(new[] {"bogus"}); ErrorReport.IsOkToInteractWithUser = false; Assert.Throws<ErrorReport.ProblemNotificationSentToUserException>(() => { locator.LocateFile("foo.txt", "booo hooo"); }); }
public void LocateFile_FileNoteFound_ReturnsEmptyString() { var locator = new FileLocator(new[] { "bogus" }); ErrorReport.IsOkToInteractWithUser = false; Assert.IsEmpty(locator.LocateFile("foo.txt")); }