Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ dependencies = [
# This limit can be removed after https://github.com/apache/airflow/issues/35234 is fixed
"connexion[flask]>=2.10.0,<3.0",
"cron-descriptor>=1.2.24",
"croniter>=0.3.17",
"croniter>=2.0.2",
"cryptography>=39.0.0",
"deprecated>=1.2.13",
"dill>=0.2.2",
Expand Down
13 changes: 13 additions & 0 deletions tests/models/test_dag.py
Original file line number Diff line number Diff line change
Expand Up @@ -2544,6 +2544,19 @@ def subdag(parent_dag_name, child_dag_name, args):
next_subdag_info = subdag.next_dagrun_info(None)
assert next_subdag_info is None, "SubDags should never have DagRuns created by the scheduler"

def test_next_dagrun_info_on_29_feb(self):
dag = DAG(
"test_scheduler_dagrun_29_feb", start_date=timezone.datetime(2024, 1, 1), schedule="0 0 29 2 *"
)

next_info = dag.next_dagrun_info(None)
assert next_info and next_info.logical_date == timezone.datetime(2024, 2, 29)

next_info = dag.next_dagrun_info(next_info.data_interval)
assert next_info.logical_date == timezone.datetime(2028, 2, 29)
assert next_info.data_interval.start == timezone.datetime(2028, 2, 29)
assert next_info.data_interval.end == timezone.datetime(2032, 2, 29)
Comment thread
hussein-awala marked this conversation as resolved.

def test_replace_outdated_access_control_actions(self):
outdated_permissions = {
"role1": {permissions.ACTION_CAN_READ, permissions.ACTION_CAN_EDIT},
Expand Down