This is an automated email from the ASF dual-hosted git repository.
potiuk 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 4068eea28b4 Fix test directory structure for airflow-ctl distributio
(#48093)
4068eea28b4 is described below
commit 4068eea28b4856a891193bbcf19983fc18b46a6a
Author: Jarek Potiuk <[email protected]>
AuthorDate: Sat Mar 22 13:08:54 2025 +0100
Fix test directory structure for airflow-ctl distributio (#48093)
The "tests" folder is root folder for all the tests, it should not be
a Python package - similarly as in all other distributions, the "tests"
folder should be just root folder for all test python packages.
Also - we should not have some "generic" package name as the top
packages in "tests" folder - becuase that has high potential for
conflicting with other - similarly named packages, the convention
we use for all the packages is one of the two:
* unit,integration,system as top level (providers/airflow-core) in
case the distribution has those three different type of tests
* "distribution_folder_name" (with underscore instead of dash)
when only unit tests are expected to be in the module (for
example in "task_sdk"
The `airflow-ctl` is rather unit-test-only distribution, so the
convention to avoid conflicts is `tests/airflow_ctl`. This
is what we use here.
---
.github/CODEOWNERS | 3 +++
airflow-ctl/tests/{ => airflow_ctl}/__init__.py | 0
airflow-ctl/tests/{ => airflow_ctl}/api/test_client.py | 0
airflow-ctl/tests/{ => airflow_ctl}/api/test_operations.py | 0
airflow-ctl/tests/{ => airflow_ctl}/commands/__init__.py | 0
airflow-ctl/tests/{ => airflow_ctl}/commands/test_auth_command.py | 0
6 files changed, 3 insertions(+)
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
index 5316b154392..257b6888b5b 100644
--- a/.github/CODEOWNERS
+++ b/.github/CODEOWNERS
@@ -26,6 +26,9 @@
/airflow-core/src/airflow/api_fastapi/ @ephraimbuddy @pierrejeambrun @rawwar
/airflow-core/src/airflow/api_fastapi/execution_api/ @ashb @kaxil @amoghrajesh
+# Airflow CTL
+/airflow-ctl/ @bugraoz93 @kaxil @potiuk
+
# Auth manager
/airflow-core/src/airflow/api_fastapi/auth/ @vincbeck
diff --git a/airflow-ctl/tests/__init__.py
b/airflow-ctl/tests/airflow_ctl/__init__.py
similarity index 100%
rename from airflow-ctl/tests/__init__.py
rename to airflow-ctl/tests/airflow_ctl/__init__.py
diff --git a/airflow-ctl/tests/api/test_client.py
b/airflow-ctl/tests/airflow_ctl/api/test_client.py
similarity index 100%
rename from airflow-ctl/tests/api/test_client.py
rename to airflow-ctl/tests/airflow_ctl/api/test_client.py
diff --git a/airflow-ctl/tests/api/test_operations.py
b/airflow-ctl/tests/airflow_ctl/api/test_operations.py
similarity index 100%
rename from airflow-ctl/tests/api/test_operations.py
rename to airflow-ctl/tests/airflow_ctl/api/test_operations.py
diff --git a/airflow-ctl/tests/commands/__init__.py
b/airflow-ctl/tests/airflow_ctl/commands/__init__.py
similarity index 100%
rename from airflow-ctl/tests/commands/__init__.py
rename to airflow-ctl/tests/airflow_ctl/commands/__init__.py
diff --git a/airflow-ctl/tests/commands/test_auth_command.py
b/airflow-ctl/tests/airflow_ctl/commands/test_auth_command.py
similarity index 100%
rename from airflow-ctl/tests/commands/test_auth_command.py
rename to airflow-ctl/tests/airflow_ctl/commands/test_auth_command.py