You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2020/03/19 17:41:49 UTC

[GitHub] [airflow] potiuk commented on a change in pull request #7770: [AIRFLOW-7069] Fix cloudsql system tests

potiuk commented on a change in pull request #7770: [AIRFLOW-7069] Fix cloudsql system tests
URL: https://github.com/apache/airflow/pull/7770#discussion_r395207261
 
 

 ##########
 File path: tests/providers/google/cloud/hooks/test_cloud_sql.py
 ##########
 @@ -1210,32 +1198,30 @@ def test_hook_with_not_too_long_unix_socket_path(self, get_connection):
         self.assertEqual('postgres', connection.conn_type)
         self.assertEqual('testdb', connection.schema)
 
-    @mock.patch("airflow.providers.google.cloud.hooks.cloud_sql.CloudSQLDatabaseHook.get_connection")
-    def test_hook_with_correct_parameters_postgres(self, get_connection):
-        uri = "gcpcloudsql://user:password@127.0.0.1:3200/testdb?database_type=postgres&" \
-              "project_id=example-project&location=europe-west1&instance=testdb&" \
-              "use_proxy=False&use_ssl=False"
+    def _verify_postgres_connection(self, get_connection, uri):
 
 Review comment:
   Me too (as you will see in many places below) . But sometimes it's quite ok to add some DRYness to the DAMPness. Especially when you actually test something else those tests are DAMP-first DRY-little.
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services