public void GetFinanceDataFromYahoo() { IFinanceDataService some = FinanceDataServiceFactory.getWeatherDataService(FinanceDataServiceFactory.FinanceDataImport.YAHOO); FinanceData yahooInstance = some.getFinanceData("GOOG"); Assert.IsInstanceOfType(yahooInstance, typeof(FinanceData)); }
static void Main(string[] args) { IFinanceDataService some = FinanceDataServiceFactory.getWeatherDataService(FinanceDataServiceFactory.FinanceDataImport.YAHOO); FinanceData yahooInstance = some.getFinanceData("GOOG"); Console.WriteLine(yahooInstance.ToString()); IFinanceDataService some2 = FinanceDataServiceFactory.getWeatherDataService(FinanceDataServiceFactory.FinanceDataImport.GOOGLE); FinanceData googleInstance = some2.getFinanceData("INTC"); Console.WriteLine(googleInstance.ToString()); }
public void WrongSymbol() { IFinanceDataService some = FinanceDataServiceFactory.getWeatherDataService(FinanceDataServiceFactory.FinanceDataImport.YAHOO); FinanceData yahooInstance = some.getFinanceData("SDFDFDPOI"); }
public void NoConnection() { IFinanceDataService some = FinanceDataServiceFactory.getWeatherDataService(FinanceDataServiceFactory.FinanceDataImport.YAHOO); FinanceData yahooInstance = some.getFinanceData("GOOG"); }