code: def test_get_conn_kerberos_security_mode(
      self,
      socket_mock,
      mock_kerberos_security_mode,
      mock_kerberos_client,
      mock_session,
  ):
      with patch(
          "airflow.providers.apache.hdfs.hooks.webhdfs.WebHDFSHook.get_connection",
          return_value=Connection(host="host_1", port=123),
      ) as mock_get_connection:
          socket_mock.socket.return_value.connect_ex.return_value = 0
          conn = self.webhdfs_hook.get_conn()
  
          connection = mock_get_connection.return_value
          mock_kerberos_client.assert_called_once_with(
              f"http://{connection.host}:{connection.port}",
              session=mock_session.return_value,
          )
          assert conn == mock_kerberos_client.return_value
  
imports: from __future__ import annotations
  from unittest.mock import call, patch
  import pytest
  from hdfs import HdfsError
  from airflow.models.connection import Connection
  from airflow.providers.apache.hdfs.hooks.webhdfs import AirflowWebHDFSHookException, WebHDFSHook
label_desc: Use image node_id 6 for calling the TestWebHDFSHook obj's underlying member method code with example usage: obj.test_get_conn_kerberos_security_mode(socket_mock, mock_kerberos_security_mode, mock_kerberos_client, mock_session) without return types