I can put a new file and create the associated pdf
This commit is contained in:
@@ -417,6 +417,25 @@ class TestUpdateStatus:
|
||||
# Verify exception details
|
||||
assert exc_info.value.current_status == ProcessingStatus.FAILED
|
||||
assert exc_info.value.target_status == ProcessingStatus.FAILED
|
||||
|
||||
def test_i_can_update_job_status(
|
||||
self,
|
||||
job_service,
|
||||
sample_document_id,
|
||||
sample_task_id
|
||||
):
|
||||
"""Test that failed job cannot be marked as failed again."""
|
||||
# Create, start, and fail a job
|
||||
created_job = job_service.create_job(sample_document_id, sample_task_id)
|
||||
job_service.mark_job_as_started(created_job.id)
|
||||
|
||||
# Execute without error message
|
||||
result = job_service.update_job_status(created_job.id, ProcessingStatus.SAVING_OBJECT)
|
||||
|
||||
# Verify status transition
|
||||
assert result is not None
|
||||
assert result.status == ProcessingStatus.SAVING_OBJECT
|
||||
assert result.error_message is None
|
||||
|
||||
|
||||
class TestDeleteJob:
|
||||
|
||||
Reference in New Issue
Block a user