Skip to content

Commit

Permalink
Resolve deprecations in serialization tests (#40625)
Browse files Browse the repository at this point in the history
  • Loading branch information
boraberke authored Jul 5, 2024
1 parent ec5da92 commit 2eda737
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
4 changes: 0 additions & 4 deletions tests/deprecations_ignore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@
- tests/models/test_xcom.py::TestXCom::test_set_serialize_call_old_signature


# Serialization
- tests/serialization/test_dag_serialization.py::TestStringifiedDAGs::test_custom_dep_detector


# WWW
- tests/www/api/experimental/test_dag_runs_endpoint.py::TestDagRunsEndpoint::test_get_dag_runs_success
- tests/www/api/experimental/test_dag_runs_endpoint.py::TestDagRunsEndpoint::test_get_dag_runs_success_with_capital_state_parameter
Expand Down
7 changes: 6 additions & 1 deletion tests/serialization/test_dag_serialization.py
Original file line number Diff line number Diff line change
Expand Up @@ -1712,7 +1712,12 @@ def test_custom_dep_detector(self):
mode="reschedule",
)
CustomDepOperator(task_id="hello", bash_command="hi")
dag = SerializedDAG.to_dict(dag)
with pytest.warns(
RemovedInAirflow3Warning,
match=r"Use of a custom dependency detector is deprecated\. "
r"Support will be removed in a future release\.",
):
dag = SerializedDAG.to_dict(dag)
assert sorted(dag["dag"]["dag_dependencies"], key=lambda x: tuple(x.values())) == sorted(
[
{
Expand Down

0 comments on commit 2eda737

Please sign in to comment.