update time handling for more tests

This commit is contained in:
stvnrlly
2022-11-10 16:54:48 -05:00
parent b50cb4712f
commit 3528bd37e1
10 changed files with 43 additions and 43 deletions

View File

@@ -4,13 +4,13 @@ from app.dao.date_util import get_current_financial_year_start_year
# see get_financial_year for conversion of financial years.
@freeze_time("2017-03-31 22:59:59.999999")
@freeze_time("2017-04-01 03:59:59.999999")
def test_get_current_financial_year_start_year_before_march():
current_fy = get_current_financial_year_start_year()
assert current_fy == 2016
@freeze_time("2017-03-31 23:00:00.000000")
@freeze_time("2017-04-01 04:00:00.000000")
def test_get_current_financial_year_start_year_after_april():
current_fy = get_current_financial_year_start_year()
assert current_fy == 2017