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 2022/02/04 16:59:15 UTC

[GitHub] [airflow] dstandish commented on a change in pull request #21326: Refactor SSH tests to not use SSH server in operator tests

dstandish commented on a change in pull request #21326:
URL: https://github.com/apache/airflow/pull/21326#discussion_r799647483



##########
File path: tests/providers/ssh/hooks/test_ssh.py
##########
@@ -739,6 +740,21 @@ def test_openssh_private_key(self):
             session.delete(conn)
             session.commit()
 
+    def test_exec_ssh_client_command(self):
+        hook = SSHHook(
+            ssh_conn_id='ssh_default',
+            conn_timeout=30,
+            banner_timeout=100,
+        )
 
-if __name__ == '__main__':
-    unittest.main()
+        for attempt in tenacity.Retrying(stop=tenacity.stop_after_attempt(5)):

Review comment:
       could this always fail silently and do we care about that?

##########
File path: tests/providers/ssh/hooks/test_ssh.py
##########
@@ -739,6 +740,21 @@ def test_openssh_private_key(self):
             session.delete(conn)
             session.commit()
 
+    def test_exec_ssh_client_command(self):
+        hook = SSHHook(
+            ssh_conn_id='ssh_default',
+            conn_timeout=30,
+            banner_timeout=100,
+        )
 
-if __name__ == '__main__':
-    unittest.main()
+        for attempt in tenacity.Retrying(stop=tenacity.stop_after_attempt(5)):

Review comment:
       could this always fail silently and if so do we care about that?




-- 
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-unsubscribe@airflow.apache.org

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