|
1 | 1 | import random |
2 | 2 | import string |
3 | | -from datetime import datetime, timedelta |
| 3 | +from datetime import timedelta |
4 | 4 | from pathlib import Path |
5 | 5 | from typing import Dict, Optional |
6 | 6 | from unittest.mock import patch |
@@ -875,14 +875,14 @@ def test_shows_error_message_when_build_log_streaming_fails( |
875 | 875 |
|
876 | 876 |
|
877 | 877 | @pytest.mark.respx(base_url=settings.base_api_url) |
878 | | -@pytest.mark.time_machine(datetime(2025, 11, 1), tick=False) |
879 | 878 | @patch("fastapi_cloud_cli.commands.deploy.WAITING_MESSAGES", ["short wait message"]) |
880 | 879 | def test_short_wait_messages( |
881 | 880 | logged_in_cli: None, |
882 | 881 | tmp_path: Path, |
883 | 882 | respx_mock: respx.MockRouter, |
884 | 883 | time_machine: TimeMachineFixture, |
885 | 884 | ) -> None: |
| 885 | + time_machine.move_to("2025-11-01 13:00:00", tick=False) |
886 | 886 | app_data = _get_random_app() |
887 | 887 | team_data = _get_random_team() |
888 | 888 | app_id = app_data["id"] |
@@ -942,14 +942,15 @@ def build_logs_handler(request: httpx.Request, route: respx.Route) -> Response: |
942 | 942 |
|
943 | 943 |
|
944 | 944 | @pytest.mark.respx(base_url=settings.base_api_url) |
945 | | -@pytest.mark.time_machine(datetime(2025, 11, 1), tick=False) |
946 | 945 | @patch("fastapi_cloud_cli.commands.deploy.LONG_WAIT_MESSAGES", ["long wait message"]) |
947 | 946 | def test_long_wait_messages( |
948 | 947 | logged_in_cli: None, |
949 | 948 | tmp_path: Path, |
950 | 949 | respx_mock: respx.MockRouter, |
951 | 950 | time_machine: TimeMachineFixture, |
952 | 951 | ) -> None: |
| 952 | + time_machine.move_to("2025-11-01 13:00:00", tick=False) |
| 953 | + |
953 | 954 | app_data = _get_random_app() |
954 | 955 | team_data = _get_random_team() |
955 | 956 | app_id = app_data["id"] |
|
0 commit comments