public async Task GetQuoteEndpointTest() { var key = _realKeySrvice.GetKey(); _apiKeyServiceMock.Setup(q => q.GetKey()).Returns(key); var result = await _alphaVantageServiceReal.GetQuoteEndpointAsync(_testSymbol); Assert.NotNull(result); Assert.AreEqual(_testSymbol, result.Symbol); }
public async Task <IActionResult> GetQuoteEndpointAsync(string symbol) { var result = await _alphaVantageService.GetQuoteEndpointAsync(symbol); return(Ok(new { symbol, Data = result, })); }