Skip to content

Conversation

@potiuk
Copy link
Member

@potiuk potiuk commented Jun 22, 2025

After #51930, we can now remove "pytest.mark.db_test" in all providers that used db only to create connections. This PR is the "trial" attempt of doing so and it verifies that it is a viable thing to do. It:

  • removes all pytest.mark.db_test markers from airbyte
  • removes / reshuffles many pytest.mark.db_tests in amazon
  • adds pre-commit that we can use to guard that no new pytest.mark.db_test markers will be added in providers that we already cleaned up (for example airbyte)

This PR, when merged will be followed up with an issue where we will ask contributors to apply the same approach to all the remaining providers - where I will describe in detail the process of removing the markers.

This is part of the #42632 which has the long-term target of making all the provider tests non-db tests and simplifying our test setup.


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

After apache#51930, we can now remove "pytest.mark.db_test" in all providers
that used db only to create connections. This PR is the "trial" attempt
of doing so and it verifies that it is a viable thing to do. It:

* removes all pytest.mark.db_test markers from airbyte
* removes / reshuffles many pytest.mark.db_tests in amazon
* adds pre-commit that we can use to guard that no new
  pytest.mark.db_test markers will be added in providers that we
  already cleaned up (for example airbyte)

This PR, when merged will be followed up with an issue where we will ask
contributors to apply the same approach to all the remaining providers -
where I will describe in detail the process of removing the markers.

This is part of the apache#42632 which has the long-term target of making all
the provider tests non-db tests and simplifying our test setup.
@potiuk potiuk force-pushed the remove-pytest-mark-db-in-a-number-of-tests branch from 69b7030 to 09eff8e Compare June 22, 2025 11:08
@potiuk potiuk merged commit 3bf83f2 into apache:main Jun 22, 2025
98 checks passed
@potiuk potiuk deleted the remove-pytest-mark-db-in-a-number-of-tests branch June 22, 2025 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants