@@ -2833,9 +2833,9 @@ def task_func(ctx, item, idx, items):
28332833 # With tolerated_failure_count=1, executor stops when failure_count > 1 (at 2 failures)
28342834 # Executor terminates early rather than executing all 100 tasks
28352835 assert executed_count ["value" ] < 100
2836- assert (
2837- result . completion_reason == CompletionReason . FAILURE_TOLERANCE_EXCEEDED
2838- ), executed_count
2836+ assert result . completion_reason == CompletionReason . FAILURE_TOLERANCE_EXCEEDED , (
2837+ executed_count
2838+ )
28392839 assert sum (1 for item in result .all if item .status == BatchItemStatus .FAILED ) == 2
28402840 assert (
28412841 sum (1 for item in result .all if item .status == BatchItemStatus .SUCCEEDED ) < 98
@@ -2965,9 +2965,9 @@ def slow_branch():
29652965
29662966 # Slow branch may or may not have started (depends on thread scheduling)
29672967 # but it definitely should not have completed
2968- assert (
2969- operation_tracker . slow_completed . call_count == 0
2970- ), "Executor should return before slow branch completes"
2968+ assert operation_tracker . slow_completed . call_count == 0 , (
2969+ "Executor should return before slow branch completes"
2970+ )
29712971
29722972 # Result should show MIN_SUCCESSFUL_REACHED
29732973 assert result .completion_reason == CompletionReason .MIN_SUCCESSFUL_REACHED
@@ -3019,9 +3019,9 @@ def slow_func():
30193019 result = executor .execute (execution_state , executor_context )
30203020
30213021 # Executor should have returned before slow branch completed
3022- assert (
3023- not slow_branch_mock . completed . called
3024- ), "Executor should return before slow branch completes"
3022+ assert not slow_branch_mock . completed . called , (
3023+ "Executor should return before slow branch completes"
3024+ )
30253025
30263026 # Result should show MIN_SUCCESSFUL_REACHED
30273027 assert result .completion_reason == CompletionReason .MIN_SUCCESSFUL_REACHED
0 commit comments