Ejemplo n.º 1
0
 public void testWritingMinuteStockPriceHistoryToJSONFiles()
 {
     foreach (string symbol in stockList)
     {
         string filepath = StockHistory.Gather10daysByTheMinute(testingHttpClient.client, testingHttpClient.apiKey, symbol, testingHttpClient.path);
         Assert.IsTrue(File.Exists(filepath));
         System.Threading.Thread.Sleep(500);
     }
 }
 private static void StoreNewSymbolsByMinuteData(HttpClient client, string apiKey, string tradeDataPath, List <string> symbols)
 {
     foreach (string symbol in symbols)
     {
         Log.write($"Updating Market Hours for Symbols {symbol}");
         try
         {
             string newStockPath = StockHistory.Gather10daysByTheMinute(client, apiKey, symbol, tradeDataPath);
             Log.write($"{DateTime.Now.ToString()} {symbol} minute history as been added to {newStockPath}");
         }
         catch (Exception ex)
         {
             Log.write(ex);
         }
         Ultility.delay(250);
     }
 }