mirror of
https://github.com/bspeice/metrik
synced 2024-11-23 07:38:09 -05:00
Fix the Options quotes not getting the right symbol
This commit is contained in:
parent
c3484ac0cc
commit
64bcb9cc1d
@ -16,7 +16,7 @@ class OptionsFlow(Flow):
|
|||||||
live=self.live)
|
live=self.live)
|
||||||
yield optionable
|
yield optionable
|
||||||
|
|
||||||
options_quotes = [TradekingOptionsQuotes(symbol=s,
|
options_quotes = [TradekingOptionsQuotes(symbol=s['Stock Symbol'],
|
||||||
current_datetime=self.present,
|
current_datetime=self.present,
|
||||||
live=self.live)
|
live=self.live)
|
||||||
for s in optionable.output().retrieve()['companies']]
|
for s in optionable.output().retrieve()['companies']]
|
||||||
|
@ -8,3 +8,10 @@ class CboeTest(TestCase):
|
|||||||
def test_optionable_list(self):
|
def test_optionable_list(self):
|
||||||
companies = CboeOptionableList.retrieve_data()['companies']
|
companies = CboeOptionableList.retrieve_data()['companies']
|
||||||
assert len(companies) > 2000
|
assert len(companies) > 2000
|
||||||
|
|
||||||
|
|
||||||
|
def test_optionable_list_format(self):
|
||||||
|
companies = CboeOptionableList.retrieve_data()['companies']
|
||||||
|
symbols = [c['Stock Symbol'] for c in companies]
|
||||||
|
|
||||||
|
assert 'AAPL' in symbols
|
Loading…
Reference in New Issue
Block a user