Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move core system tests outside of providers system tests #39335

Merged
merged 2 commits into from
May 7, 2024
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ via ``allowed_states`` and ``failed_states`` parameters.

Also for this action you can use sensor in the deferrable mode:

.. exampleinclude:: /../../tests/system/providers/core/example_external_task_parent_deferrable.py
.. exampleinclude:: /../../tests/system/core/example_external_task_parent_deferrable.py
:language: python
:dedent: 4
:start-after: [START howto_external_task_async_sensor]
Expand Down
7 changes: 7 additions & 0 deletions docs/apache-airflow/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -175,3 +175,10 @@ so coding will always be required.

Database Migrations <migrations-ref>
Database ERD Schema <database-erd-ref>

.. toctree::
:hidden:
:maxdepth: 1
:caption: System tests

System Tests <_api/tests/system/core/index>
3 changes: 2 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,11 @@
# By default (e.g. on RTD), build docs for `airflow` package
PACKAGE_NAME = os.environ.get("AIRFLOW_PACKAGE_NAME", "apache-airflow")
PACKAGE_DIR: pathlib.Path
SYSTEM_TESTS_DIR: pathlib.Path | None
if PACKAGE_NAME == "apache-airflow":
PACKAGE_DIR = ROOT_DIR / "airflow"
PACKAGE_VERSION = airflow.__version__
SYSTEM_TESTS_DIR = None
SYSTEM_TESTS_DIR = (ROOT_DIR / "tests" / "system" / "core").resolve(strict=True)
elif PACKAGE_NAME.startswith("apache-airflow-providers-"):
from provider_yaml_utils import load_package_data

Expand Down
2 changes: 1 addition & 1 deletion tests/always/test_example_dags.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def get_python_excluded_providers_folders() -> list[str]:


def example_not_excluded_dags():
example_dirs = ["airflow/**/example_dags/example_*.py", "tests/system/providers/**/example_*.py"]
example_dirs = ["airflow/**/example_dags/example_*.py", "tests/system/**/example_*.py"]
excluded_providers_folders = get_suspended_providers_folders()
excluded_providers_folders.extend(get_python_excluded_providers_folders())
possible_prefixes = ["airflow/providers/", "tests/system/providers/"]
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
catchup=False,
tags=["example", "async", "core"],
) as dag:
dummy_task = BashOperator(
BashOperator(
task_id="child_task",
bash_command="echo 1; sleep 1; echo 2; sleep 2; echo 3; sleep 3",
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"success",
"failed",
],
execution_date="{{execution_date}}",
logical_date="{{ logical_date }}",
poke_interval=5,
reset_dag_run=True,
wait_for_completion=True,
Expand Down