This is an automated email from the ASF dual-hosted git repository.
bugraoz pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new 3f0e75ea857 Mark flaky airflowctl test (#51505)
3f0e75ea857 is described below
commit 3f0e75ea85734861eed94db99d65bd6c1f3f0dfc
Author: Bugra Ozturk <[email protected]>
AuthorDate: Sun Jun 8 16:03:13 2025 +0200
Mark flaky airflowctl test (#51505)
* add devel-common into dev dependency group
* add markers definition
---
airflow-ctl/pyproject.toml | 5 ++++-
airflow-ctl/tests/airflow_ctl/ctl/commands/test_auth_command.py | 2 ++
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/airflow-ctl/pyproject.toml b/airflow-ctl/pyproject.toml
index 0cd8f98ece4..1042169796d 100644
--- a/airflow-ctl/pyproject.toml
+++ b/airflow-ctl/pyproject.toml
@@ -113,6 +113,7 @@ docs = [
]
dev = [
"apache-airflow-ctl[dev]",
+ "apache-airflow-devel-common",
]
codegen = [
"datamodel-code-generator[http]==0.28.2",
@@ -156,7 +157,9 @@ addopts = [
"--disable-warnings",
"--asyncio-mode=strict",
]
-
+markers = [
+ "flaky(reruns, reruns_delay): retry test on failure using
pytest-rerunfailures"
+]
norecursedirs = [
".eggs",
]
diff --git a/airflow-ctl/tests/airflow_ctl/ctl/commands/test_auth_command.py
b/airflow-ctl/tests/airflow_ctl/ctl/commands/test_auth_command.py
index bfe632b2395..13acfbabbb1 100644
--- a/airflow-ctl/tests/airflow_ctl/ctl/commands/test_auth_command.py
+++ b/airflow-ctl/tests/airflow_ctl/ctl/commands/test_auth_command.py
@@ -22,6 +22,7 @@ import os
from unittest import mock
from unittest.mock import patch
+import pytest
from platformdirs import user_config_path
from airflowctl.api.client import ClientKind
@@ -39,6 +40,7 @@ class TestCliAuthCommands:
@patch.dict(os.environ, {"AIRFLOW_CLI_TOKEN": "TEST_TOKEN"})
@patch.dict(os.environ, {"AIRFLOW_CLI_ENVIRONMENT": "TEST_AUTH_LOGIN"})
@patch("airflowctl.api.client.keyring")
+ @pytest.mark.flaky(reruns=3, reruns_delay=10)
def test_login(self, mock_keyring, api_client_maker):
api_client = api_client_maker(
path="/auth/token/cli",