This is an automated email from the ASF dual-hosted git repository. ephraimanierobi pushed a commit to branch v2-5-test in repository https://gitbox.apache.org/repos/asf/airflow.git
commit 43b8ea65a2b3868c849bab856f85f46e9b8f7a67 Author: Andrey Anshin <[email protected]> AuthorDate: Tue Dec 27 11:21:15 2022 +0400 Rerun flaky PinotDB integration test (#28562) (cherry picked from commit fff9fd3a53d239625692e141a996e98db5b8d88f) --- setup.py | 1 - tests/integration/providers/apache/pinot/hooks/test_pinot.py | 2 ++ tests/providers/ssh/hooks/test_ssh.py | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/setup.py b/setup.py index a132eb861c..622d630c05 100644 --- a/setup.py +++ b/setup.py @@ -369,7 +369,6 @@ devel_only = [ "flake8>=3.9.0", "flake8-colors", "flake8-implicit-str-concat", - "flaky", "gitpython", "ipdb", # make sure that we are using stable sorting order from 5.* version (some changes were introduced diff --git a/tests/integration/providers/apache/pinot/hooks/test_pinot.py b/tests/integration/providers/apache/pinot/hooks/test_pinot.py index d99e8efdf4..432521f0ae 100644 --- a/tests/integration/providers/apache/pinot/hooks/test_pinot.py +++ b/tests/integration/providers/apache/pinot/hooks/test_pinot.py @@ -26,6 +26,8 @@ from airflow.providers.apache.pinot.hooks.pinot import PinotDbApiHook @pytest.mark.integration("pinot") class TestPinotDbApiHookIntegration: + # This test occasionally fail in the CI. Re-run this test if it failed after timeout but only once. + @pytest.mark.flaky(reruns=1, reruns_delay=30) @mock.patch.dict("os.environ", AIRFLOW_CONN_PINOT_BROKER_DEFAULT="pinot://pinot:8000/") def test_should_return_records(self): hook = PinotDbApiHook() diff --git a/tests/providers/ssh/hooks/test_ssh.py b/tests/providers/ssh/hooks/test_ssh.py index 6448d88efe..7789ee754c 100644 --- a/tests/providers/ssh/hooks/test_ssh.py +++ b/tests/providers/ssh/hooks/test_ssh.py @@ -890,7 +890,7 @@ class TestSSHHook: session.delete(conn) session.commit() - @pytest.mark.flaky(max_runs=5, min_passes=1) + @pytest.mark.flaky(reruns=5) def test_exec_ssh_client_command(self): hook = SSHHook( ssh_conn_id="ssh_default", @@ -907,7 +907,7 @@ class TestSSHHook: ) assert ret == (0, b"airflow\n", b"") - @pytest.mark.flaky(max_runs=5, min_passes=1) + @pytest.mark.flaky(reruns=5) def test_command_timeout(self): hook = SSHHook( ssh_conn_id="ssh_default",
