public void throw_an_exception_if_source_file_is_not_found() { var csvFileMarketDataSource = new CsvFileMarketDataSource(); Action action = () => csvFileMarketDataSource.GetAllOffers("abc"); action.ShouldThrow <MarketFileDoesNotExistException>(); }
public void get_lender_offers_from_a_csv_file() { var csvFileFullPath = Path.Combine(Path.GetDirectoryName(typeof(CsvFileMarketDataSourceShould).GetTypeInfo().Assembly.Location), "market.csv"); var csvFileMarketDataSource = new CsvFileMarketDataSource(); var offers = csvFileMarketDataSource.GetAllOffers(csvFileFullPath); offers.Should().BeOfType <LoanOffers>(); }