Skip to content

Commit

Permalink
update get_bars testcase
Browse files Browse the repository at this point in the history
  • Loading branch information
kuanghy committed Jun 16, 2024
1 parent 78c298a commit 78557b8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -1115,6 +1115,10 @@ def test_get_bars():
print(df)
assert not df.empty

arr = get_bars("M9999.XDCE", 48, unit='1M', fields='close', end_dt=None, df=False)
assert isinstance(arr, np.ndarray)
assert len(arr) == 48


def test_get_bars2():
codes = ["600000.XSHG", "000001.XSHG", "A2205.XDCE"]
Expand Down

0 comments on commit 78557b8

Please sign in to comment.