diff --git a/backend/tests/endpoints/test_streaming.py b/backend/tests/endpoints/test_streaming.py index 6c93689d7..46d33b183 100644 --- a/backend/tests/endpoints/test_streaming.py +++ b/backend/tests/endpoints/test_streaming.py @@ -5548,7 +5548,7 @@ def test_a_streamed_state_is_the_one_cloud_sync_serves_for_its_slot( "Game.20261008-153825000000.state.auto", "mgba", core="mgba", - updated_at=datetime(2099, 1, 1, tzinfo=timezone.utc), + updated_at=datetime.now(timezone.utc) + timedelta(days=365), ) served = retroarch_sync.resolve_state_by_slot( @@ -5683,7 +5683,7 @@ def test_hydrate_pushes_a_newer_cloud_synced_state_of_the_booted_core( admin_user, "Game.state.auto", "bsnes", - updated_at=datetime(2099, 1, 1, tzinfo=timezone.utc), + updated_at=datetime.now(timezone.utc) + timedelta(days=365), ) push = _hydrate_core( rom, admin_user, "retroarch:bsnes", states.StateCore("bsnes", False) diff --git a/backend/tests/endpoints/test_sync.py b/backend/tests/endpoints/test_sync.py index 2c132b50b..86a164a02 100644 --- a/backend/tests/endpoints/test_sync.py +++ b/backend/tests/endpoints/test_sync.py @@ -1734,12 +1734,12 @@ class TestNegotiateBaseline: assert upload.status_code == status.HTTP_200_OK # The server moves on after the boundary the upload recorded. + later = (datetime.now(timezone.utc) + timedelta(days=365)).replace( + microsecond=0 + ) db_save_handler.update_save( upload.json()["id"], - { - "content_hash": "server_new", - "updated_at": datetime(2099, 1, 1, tzinfo=timezone.utc), - }, + {"content_hash": "server_new", "updated_at": later}, ) with mock.patch( @@ -1755,7 +1755,7 @@ class TestNegotiateBaseline: "file_name": "chain.sav", "slot": "autosave", "content_hash": "client_hash", - "updated_at": "2099-01-01T00:00:00Z", + "updated_at": later.isoformat(), "file_size_bytes": 100, } ],