Taragolis commented on code in PR #28755:
URL: https://github.com/apache/airflow/pull/28755#discussion_r1067316123
##########
tests/system/providers/amazon/aws/utils/__init__.py:
##########
@@ -92,15 +93,15 @@ def _fetch_from_ssm(key: str, test_name: str | None = None)
-> str:
:return: The value of the provided key from SSM
"""
_test_name: str = test_name if test_name else _get_test_name()
- ssm_client: BaseClient = boto3.client("ssm")
+ hook = SsmHook()
Review Comment:
> Thinking this through, that would mean that the connection itself is not
being tested.
We tests connections for AwsBaseHook and all other helpers. Actually there
is 3 cases and all of them tested:
1. aws_conn_id = None
2. aws_conn_id = not-existed-conn, we know only after we tried connect to DB
(one in the future we would remove this one)
3. aws_conn_id = exists-conn
So we don't need test for all Hooks which based on AwsBaseHook and
AwsGenericHook and how they obtain connection from Airflow.
The actual error here happen in this test
https://github.com/apache/airflow/blob/877189916900c930b2c4b92101d46d2f98eb9077/tests/always/test_example_dags.py#L62-L68
I'm not familiar with this test, but seems like it test that example DAGs do
not perform queries to Airflow Database during import example dags:
https://github.com/apache/airflow/pull/7419
I don't know maybe this test less relevant nowadays
--
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]