Add tests for ohlcv_get_available_data
This commit is contained in:
@@ -29,9 +29,10 @@ class JsonDataHandler(IDataHandler):
|
||||
:param datadir: Directory to search for ohlcv files
|
||||
:return: List of Pair
|
||||
"""
|
||||
_tmp = [re.search(r'^([a-zA-Z_]+)\-(\S+)(?=.json)', p.name)
|
||||
_tmp = [re.search(r'^([a-zA-Z_]+)\-(\d+\S+)(?=.json)', p.name)
|
||||
for p in datadir.glob(f"*.{cls._get_file_extension()}")]
|
||||
return [(match[1].replace('_', '/'), match[2]) for match in _tmp if len(match.groups()) > 1]
|
||||
return [(match[1].replace('_', '/'), match[2]) for match in _tmp
|
||||
if match and len(match.groups()) > 1]
|
||||
|
||||
@classmethod
|
||||
def ohlcv_get_pairs(cls, datadir: Path, timeframe: str) -> List[str]:
|
||||
|
Reference in New Issue
Block a user