whitespace, variable renames
This commit is contained in:
parent
06340ed521
commit
de833d75af
2 changed files with 14 additions and 6 deletions
|
|
@ -192,8 +192,10 @@ class DataSource:
|
|||
@property
|
||||
def api_url(self):
|
||||
return (
|
||||
f'https://{self.api_host}/v1/tickers/btc-bitcoin' if cfg.btc_only else
|
||||
f'https://{self.api_host}/v1/tickers?limit={self.asset_limit}' if self.asset_limit else
|
||||
f'https://{self.api_host}/v1/tickers/btc-bitcoin'
|
||||
if cfg.btc_only else
|
||||
f'https://{self.api_host}/v1/tickers?limit={self.asset_limit}'
|
||||
if self.asset_limit else
|
||||
f'https://{self.api_host}/v1/tickers')
|
||||
|
||||
@property
|
||||
|
|
|
|||
|
|
@ -106,10 +106,17 @@ class CmdTestScripts(CmdTestBase):
|
|||
shutil.copy2(os.path.join(refdir,'ticker-btc.json'),self.tmpdir)
|
||||
return 'ok'
|
||||
|
||||
def ticker(self, args=[], expect_list=None, cached=True, exit_val=None):
|
||||
def ticker(
|
||||
self,
|
||||
args = [],
|
||||
expect_list = None,
|
||||
cached_data = True,
|
||||
exit_val = None):
|
||||
t = self.spawn(
|
||||
'mmnode-ticker',
|
||||
(['--cached-data'] if cached else []) + self.ticker_args + args,
|
||||
(['--cached-data'] if cached_data else [])
|
||||
+ self.ticker_args
|
||||
+ args,
|
||||
exit_val = exit_val)
|
||||
if expect_list:
|
||||
t.match_expect_list(expect_list)
|
||||
|
|
@ -121,7 +128,7 @@ class CmdTestScripts(CmdTestBase):
|
|||
return t
|
||||
|
||||
def ticker2(self):
|
||||
t = self.ticker(cached=False)
|
||||
t = self.ticker(cached_data=False)
|
||||
if not cfg.skipping_deps:
|
||||
t.expect('Creating')
|
||||
t.expect('Creating')
|
||||
|
|
@ -137,7 +144,6 @@ class CmdTestScripts(CmdTestBase):
|
|||
'BTC 23250.77 1.00000000 ETH 1659.66 0.07138094'
|
||||
])
|
||||
|
||||
|
||||
def ticker4(self):
|
||||
return self.ticker(
|
||||
['--widest','--add-columns=eurusd=x,inr-indian-rupee:79.5'],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue