Skip to content

Commit 7a8bab8

Browse files
committed
Build the probe test's params without the dropped required
TaskHandlerParam no longer has required, and pydantic ignores an unknown keyword, so the test would keep passing while showing a field the wire no longer carries.
1 parent eb40692 commit 7a8bab8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎airflow-core/tests/unit/dag_processing/test_task_handler_processor.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ def _run(tmp_path, *, coordinator: str = "fake") -> TaskHandlerParsingResult:
6767
def test_returns_every_handler_the_runtime_registers(mock_parse_task_handler, tmp_path):
6868
def reply(request, comms):
6969
# Echo what the request carries, so the test can check it.
70-
param = TaskHandlerParam(name=request.bundle_name, value_schema={"type": "string"}, required=True)
70+
param = TaskHandlerParam(name=request.bundle_name, value_schema={"type": "string"})
7171
return TaskHandlerParsingResult(
7272
fileloc=request.file,
7373
task_handlers={
@@ -84,7 +84,7 @@ def reply(request, comms):
8484

8585
result = _run(tmp_path)
8686

87-
param = TaskHandlerParam(name="task-handlers", value_schema={"type": "string"}, required=True)
87+
param = TaskHandlerParam(name="task-handlers", value_schema={"type": "string"})
8888
declaration = TaskHandlerDeclaration(task_id=os.fspath(tmp_path), binding="positional", params=[param])
8989
assert result == TaskHandlerParsingResult(
9090
fileloc=os.fspath(tmp_path / "etl.artifact"),

0 commit comments

Comments
 (0)