Add small test cases

This commit is contained in:
Matthias
2021-02-09 20:03:03 +01:00
parent 86fa75b286
commit 3110d2dbb1
2 changed files with 7 additions and 1 deletions

View File

@@ -2462,6 +2462,9 @@ def test_timeframe_to_prev_date():
date = datetime.now(tz=timezone.utc)
assert timeframe_to_prev_date("5m") < date
# Does not round
time = datetime(2019, 8, 12, 13, 20, 0, tzinfo=timezone.utc)
assert timeframe_to_prev_date('5m', time) == time
def test_timeframe_to_next_date():