kaxil commented on code in PR #74924:
URL: https://github.com/apache/airflow/pull/74924#discussion_r4304546489
##########
airflow-core/tests/unit/always/test_project_structure.py:
##########
@@ -91,11 +91,32 @@ def test_providers_modules_should_have_tests(self):
"providers/fab/tests/unit/fab/www/test_security_appless.py",
"providers/fab/tests/unit/fab/www/test_security_manager.py",
"providers/fab/tests/unit/fab/www/test_session.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_auto_ml.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_batch_prediction_job.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_custom_job.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_dataset.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_endpoint_service.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_hyperparameter_tuning_job.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_model_service.py",
+
"providers/google/tests/unit/google/cloud/operators/vertex_ai/test_pipeline_job.py",
+
"providers/google/tests/unit/google/cloud/sensors/vertex_ai/test_feature_store.py",
+
"providers/google/tests/unit/google/cloud/transfers/test_bigquery_to_sql.py",
+
"providers/google/tests/unit/google/cloud/transfers/test_presto_to_gcs.py",
+ "providers/google/tests/unit/google/cloud/utils/test_bigquery.py",
+
"providers/google/tests/unit/google/cloud/utils/test_bigquery_get_data.py",
+
"providers/microsoft/azure/tests/unit/microsoft/azure/operators/test_adls.py",
+
"providers/snowflake/tests/unit/snowflake/triggers/test_snowflake_trigger.py",
+ ]
+ # Deliberately untested: link modules whose tests would only assert
constants.
+ # Remove an entry once its module gains logic worth testing.
+ EXEMPTED_TESTS = [
+ "providers/google/tests/unit/google/cloud/links/test_alloy_db.py",
"providers/google/tests/unit/google/cloud/links/test_bigquery_dts.py",
"providers/google/tests/unit/google/cloud/links/test_bigtable.py",
"providers/google/tests/unit/google/cloud/links/test_cloud_build.py",
"providers/google/tests/unit/google/cloud/links/test_cloud_functions.py",
"providers/google/tests/unit/google/cloud/links/test_cloud_memorystore.py",
+
"providers/google/tests/unit/google/cloud/links/test_cloud_monitoring.py",
Review Comment:
Was dropping the key pin intended for this one? The `CloudMonitoring*Link`
classes kept `stackdriver_notifications` and `stackdriver_policies` as keys
through the rename, and the deleted test was the only thing asserting them
(added in #73354 so stored XComs keep resolving). `BaseGoogleLink.get_link`
reads the XCom by `self.key`, so a later "finish the rename" change to the key
would pass CI and the links would go blank on existing task instances. I'd keep
`test_cloud_monitoring.py`, since a rename is exactly the failure it guards.
##########
airflow-core/tests/unit/always/test_project_structure.py:
##########
@@ -106,25 +127,11 @@ def test_providers_modules_should_have_tests(self):
"providers/google/tests/unit/google/cloud/links/test_dataproc.py",
Review Comment:
`dataproc.py`, `kubernetes_engine.py` and `translate.py` don't match the
comment above this list. They're the three modules here with real logic:
`dataproc.py` has the module `__getattr__` shim plus
`persist`/`get_link`/`__attrs_post_init__` on `DataprocLink` and
`DataprocListLink`, `KubernetesEngineClusterLink.persist` parses a dict cluster
and raises when it's missing, and the two translate `persist` methods go
through `extract_output_uri_prefix`. None of that has a direct test (the
operator tests mock the link class or its `persist`). Can these three stay in
`OVERLOOKED_TESTS`? The other 19 have no `def` at all, so they fit the
exemption.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]