Skip to content

Commit

Permalink
Cleanup test
Browse files Browse the repository at this point in the history
  • Loading branch information
jbaron committed Apr 14, 2024
1 parent 75b2094 commit 20381c6
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions tests/integration/test_alpaca.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,20 @@

class TestAlpaca(unittest.TestCase):

stocks = ["AAPL", "TSLA"]

def test_alpaca_feed(self):
feed = AlpacaHistoricStockFeed()
feed.retrieve_bars("AAPL", "TSLA", start="2024-03-01", end="2024-03-02")
run_price_item_feed(feed, ["AAPL", "TSLA"], self)
feed.retrieve_bars(*self.stocks, start="2024-03-01", end="2024-03-02")
run_price_item_feed(feed, self.stocks, self)

feed = AlpacaHistoricStockFeed()
feed.retrieve_trades("AAPL", "TSLA", start="2024-03-01T18:00:00", end="2024-03-01T18:01:00")
run_price_item_feed(feed, ["AAPL", "TSLA"], self)
feed.retrieve_trades(*self.stocks, start="2024-03-01T18:00:00", end="2024-03-01T18:01:00")
run_price_item_feed(feed, self.stocks, self)

feed = AlpacaHistoricStockFeed()
feed.retrieve_quotes("AAPL", "TSLA", start="2024-03-01T18:00:00", end="2024-03-01T18:01:00")
run_price_item_feed(feed, ["AAPL", "TSLA"], self)
feed.retrieve_quotes(*self.stocks, start="2024-03-01T18:00:00", end="2024-03-01T18:01:00")
run_price_item_feed(feed, self.stocks, self)

feed = AlpacaHistoricCryptoFeed()
feed.retrieve_bars("BTC/USDT", start="2024-03-01", end="2024-03-02", resolution=TimeFrame.Hour) # type: ignore
Expand Down

0 comments on commit 20381c6

Please sign in to comment.