This is an automated email from the ASF dual-hosted git repository.

vincbeck pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new 836bdb29c0 feat: Use 'use_ssl' parameter instead of 'ssl' + Use 
attributes of the patched function (#32305)
836bdb29c0 is described below

commit 836bdb29c0c455a5e9f84957947452e50c4d477e
Author: Joffrey Bienvenu <[email protected]>
AuthorDate: Tue Jul 4 17:47:43 2023 +0200

    feat: Use 'use_ssl' parameter instead of 'ssl' + Use attributes of the 
patched function (#32305)
---
 tests/providers/apache/impala/hooks/test_impala.py | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/tests/providers/apache/impala/hooks/test_impala.py 
b/tests/providers/apache/impala/hooks/test_impala.py
index 829a543e08..a3e1f11936 100644
--- a/tests/providers/apache/impala/hooks/test_impala.py
+++ b/tests/providers/apache/impala/hooks/test_impala.py
@@ -35,17 +35,22 @@ def impala_hook_fixture() -> ImpalaHook:
     return hook
 
 
-@patch("airflow.providers.apache.impala.hooks.impala.connect")
+@patch("airflow.providers.apache.impala.hooks.impala.connect", autospec=True)
 def test_get_conn(mock_connect):
     hook = ImpalaHook()
     hook.get_connection = MagicMock(
         return_value=Connection(
-            login="login", password="password", host="host", port=21050, 
schema="test", extra={"ssl": True}
+            login="login",
+            password="password",
+            host="host",
+            port=21050,
+            schema="test",
+            extra={"use_ssl": True},
         )
     )
     hook.get_conn()
     mock_connect.assert_called_once_with(
-        host="host", port=21050, user="login", password="password", 
database="test", ssl=True
+        host="host", port=21050, user="login", password="password", 
database="test", use_ssl=True
     )
 
 

Reply via email to