1212
1313def create_finetune_response (
1414 status : FinetuneJobStatus = FinetuneJobStatus .STATUS_RUNNING ,
15- updated_at : str = "2024-01-01T12:00:00Z" ,
15+ started_at : str = "2024-01-01T12:00:00Z" ,
1616 progress : FinetuneProgress | None = None ,
1717 job_id : str = "ft-test-123" ,
1818) -> FinetuneResponse :
@@ -30,7 +30,8 @@ def create_finetune_response(
3030 return FinetuneResponse (
3131 id = job_id ,
3232 progress = progress ,
33- updated_at = updated_at ,
33+ updated_at = started_at ,
34+ started_at = started_at ,
3435 status = status ,
3536 )
3637
@@ -359,7 +360,7 @@ def test_timezone_aware_datetime(self):
359360 """Test with different timezone for updated_at."""
360361 current_time = datetime (2024 , 1 , 1 , 12 , 0 , 30 , tzinfo = timezone .utc )
361362 finetune_job = create_finetune_response (
362- updated_at = "2024-01-01T07:00:00-05:00" , # Same as 12:00:00 UTC (EST = UTC-5)
363+ started_at = "2024-01-01T07:00:00-05:00" , # Same as 12:00:00 UTC (EST = UTC-5)
363364 progress = FinetuneProgress (estimate_available = True , seconds_remaining = 60.0 ),
364365 )
365366
@@ -385,7 +386,7 @@ def test_negative_elapsed_time_scenario(self):
385386 """Test unusual case where current time appears before updated_at."""
386387 current_time = datetime (2024 , 1 , 1 , 12 , 0 , 0 , tzinfo = timezone .utc )
387388 finetune_job = create_finetune_response (
388- updated_at = "2024-01-01T12:00:30Z" , # In the "future"
389+ started_at = "2024-01-01T12:00:30Z" , # In the "future"
389390 progress = FinetuneProgress (estimate_available = True , seconds_remaining = 100.0 ),
390391 )
391392
0 commit comments