public (bool created, string errorMessage) Generate(int id) { var data = _dataGetter.GetData(id); (bool valid, string errorMessage)result = _dataValidator.ValidateData(data); if (!result.valid) { return(result); } ReportOutput reportOutput = _dataFormatter.FormatData(data); return(_reportDistributor.DistributeReport(reportOutput)); }
public void DistributeReport_nullObject() { var ex = Assert.ThrowsException <ArgumentNullException>(() => _reportDistributor.DistributeReport(null)); }