Fix CSV OHLCV based tests (#331)#400
Merged
Merged
Conversation
…ests (#331) - Add CSVTickerDataProvider class for ticker data from CSV files - Export CSVTickerDataProvider at all package levels - Add 19 new tests for CSVOHLCVDataProvider (has_data, get_data, backtest, edge cases, symbol/market/timeframe matching) - Add 7 new tests for CSVTickerDataProvider (loading, has_data, get_data, symbol/market/data_type matching, custom identifier) - Add new test data CSV files for backtesting scenarios - Fix test_trade_price_update to use proper data fixtures
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds comprehensive test coverage for CSV data providers and introduces the new
CSVTickerDataProviderclass.Closes #331
Changes
New: CSVTickerDataProvider
has_data(),get_data(), backtest mode, and the copy pattern__init__.pychain)New Tests: CSVOHLCVDataProvider (19 tests)
has_data()with matching/mismatched symbol, market, time_framehas_data()with no dates, out-of-range end date, window_sizeget_data()with start_date and end_dateprepare_backtest_data()andget_backtest_data()New Tests: CSVTickerDataProvider (7 tests)
has_data()with matching/mismatched symbol, market, data_typeget_data()returns correct ticker dict with expected keysOther
test_trade_price_update.pydata fixtures