Modify tests to point to datahandlers

This commit is contained in:
Matthias
2019-12-25 16:41:52 +01:00
parent 9876d126ca
commit b7c1d55491
2 changed files with 14 additions and 26 deletions

View File

@@ -76,20 +76,6 @@ def store_tickerdata_file(datadir: Path, pair: str,
misc.file_dump_json(filename, data, is_zip=is_zip)
def load_trades_file(datadir: Path, pair: str,
timerange: Optional[TimeRange] = None) -> List[Dict]:
"""
Load a pair from file, either .json.gz or .json
:return: tradelist or empty list if unsuccesful
"""
filename = pair_trades_filename(datadir, pair)
tradesdata = misc.file_load_json(filename)
if not tradesdata:
return []
return tradesdata
def load_pair_history(pair: str,
timeframe: str,
datadir: Path, *,
@@ -198,12 +184,6 @@ def pair_data_filename(datadir: Path, pair: str, timeframe: str) -> Path:
return filename
def pair_trades_filename(datadir: Path, pair: str) -> Path:
pair_s = pair.replace("/", "_")
filename = datadir.joinpath(f'{pair_s}-trades.json.gz')
return filename
def _load_cached_data_for_updating(datadir: Path, pair: str, timeframe: str,
timerange: Optional[TimeRange]) -> Tuple[List[Any],
Optional[int]]: