topherinternational commented on code in PR #71692:
URL: https://github.com/apache/airflow/pull/71692#discussion_r3833855316


##########
providers/opensearch/tests/unit/opensearch/log/test_os_task_handler.py:
##########
@@ -288,6 +288,22 @@ def test_client_with_patterns(self):
         )
         assert handler.index_patterns == patterns
 
+    def test_client_no_auth(self):
+        handler = OpensearchTaskHandler(
+            base_log_folder=self.local_log_location,
+            end_of_log_mark=self.end_of_log_mark,
+            write_stdout=self.write_stdout,
+            host="localhost",
+            port=9200,
+            username="",
+            password="",
+            json_format=self.json_format,
+            json_fields=self.json_fields,
+            host_field=self.host_field,
+            offset_field=self.offset_field,
+        )
+        assert "http_auth" not in handler.client.transport.kwargs

Review Comment:
   Test added to cover "either or both not-empty should pass `http_auth`" cases.



-- 
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]

Reply via email to