Taragolis commented on code in PR #28631:
URL: https://github.com/apache/airflow/pull/28631#discussion_r1058554942


##########
tests/providers/conftest.py:
##########
@@ -0,0 +1,75 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+from __future__ import annotations
+
+import pytest
+
+from tests.test_utils import db
+
+# Providers with subpackages
+INNER_PROVIDERS = {

Review Comment:
   > but the way it is implemented now, it will also run the auto-fixture even 
if you run a single unit test. This will dramatically slow-down any iterations 
you do I am afraid (and it does not really matter if we do it only for 
Providers or for whole airflow).
   
   A lot of tests right now clear some part of DB between the run, so I can't 
say it dramatically affect of single test.
   
   
   Single test with fixture (3 runs) on Postgres in breeze
   ```console
   
   1 passed in 1.95s
   1 passed in 1.96s
   1 passed in 2.00s
   ```
   
   Single test without fixture (3 runs) on Postgres in breeze
   ```console
   
   1 passed in 1.02s
   1 passed in 0.98s
   1 passed in 0.99s
   ```
   
   So one second per run it not a big deal and if developer run all tests in 
single module or just one test class, it would be even unnoticeable.
   
   > Don't we want to do it for ALL packages that are "leaves" - not only for 
providers (including all airflow packages)?
   
   Initial problem happen because different providers packages could run 
separately for each other, e.g. SSH and Oracle and if developer do some stuff 
wrong we could find it only in main.
   
   All others tests run all together, so if one tests from Core affect another 
then most probably we notice this in Core section



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to