Skip to content

Commit f056bbd

Browse files
committed
test fixes
1 parent c176c83 commit f056bbd

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

tests/unit/task_processor/test_unit_task_processor_decorators.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
register_recurring_task,
1515
register_task_handler,
1616
)
17-
from task_processor.exceptions import InvalidArgumentsError
17+
from task_processor.exceptions import InvalidArgumentsError, TaskProcessingError
1818
from task_processor.models import RecurringTask, Task, TaskPriority
1919
from task_processor.task_registry import get_task, initialise
2020
from task_processor.task_run_method import TaskRunMethod
@@ -143,7 +143,7 @@ def some_function(first_arg: str, second_arg: str) -> None:
143143

144144
# Then
145145
assert not RecurringTask.objects.filter(task_identifier=task_identifier).exists()
146-
with pytest.raises(KeyError):
146+
with pytest.raises(TaskProcessingError):
147147
assert get_task(task_identifier)
148148

149149

tests/unit/task_processor/test_unit_task_processor_processor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -500,7 +500,7 @@ def test_run_task_runs_task_and_creates_task_run_object_when_failure(
500500
),
501501
(
502502
logging.DEBUG,
503-
f"Running task {task.task_identifier} id={task.id} args=['{msg}'] kwargs={{}}",
503+
f"Running task {task.task_identifier} id={task.id} args=('{msg}',) kwargs={{}}",
504504
),
505505
(
506506
logging.ERROR,

0 commit comments

Comments
 (0)