Skip to content

Commit

Permalink
Fix test_job_parameter_is_injected_in_task
Browse files Browse the repository at this point in the history
  • Loading branch information
shayel8 authored and JonatanMartens committed Apr 3, 2022
1 parent a3d9d44 commit 57b3eac
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/unit/task/task_builder_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,12 @@ async def test_no_additional_variables_are_added_to_result(
@pytest.mark.asyncio
async def test_job_parameter_is_injected_in_task(self, task_config: TaskConfig, mocked_job_with_adapter: Job):
def function_with_job_parameter(job: Job):
return {"job": job}
return {"received_job": job}

task = task_builder.build_task(function_with_job_parameter, task_config)
job = await task.job_handler(mocked_job_with_adapter)

assert job.variables["job"] == mocked_job_with_adapter
assert job.variables["received_job"] == mocked_job_with_adapter

@pytest.mark.asyncio
async def test_job_parameter_is_removed_after_job_handler_call(
Expand Down

0 comments on commit 57b3eac

Please sign in to comment.