diff --git a/tests/test_api.py b/tests/test_api.py index e361a1a..0705e9e 100644 --- a/tests/test_api.py +++ b/tests/test_api.py @@ -177,7 +177,7 @@ def _parse_reports(body): since = returned_full[4]["created_at"] tzone = timezone(timedelta(hours=int(since[-3:]))) - stamp = datetime.strptime("%Y-%m-%d %H:%M:%S", since[:-3]).astimezone(tzone) + stamp = datetime.strptime(since[:-3], "%Y-%m-%d %H:%M:%S.%f").replace(tzinfo=tzone) response = test_client.get( "/db_export", params={"api_key": api_key, "table": "reports", "since": stamp.isoformat()} )