code: def _basetest_sock_client_ops(self, httpd, sock):
      if not isinstance(
          self.loop, proactor_events.BaseProactorEventLoop
      ):
          # in debug mode, socket operations must fail
          # if the socket is not in blocking mode
          self.loop.set_debug(True)
          sock.setblocking(True)
          with self.assertRaises(ValueError):
              self.loop.run_until_complete(
                  self.loop.sock_connect(sock, httpd.address)
              )
          with self.assertRaises(ValueError):
              self.loop.run_until_complete(
                  self.loop.sock_sendall(
                      sock, b"GET / HTTP/1.0\r\n\r\n"
                  )
              )
          with self.assertRaises(ValueError):
              self.loop.run_until_complete(
                  self.loop.sock_recv(sock, 1024)
              )
          with self.assertRaises(ValueError):
              self.loop.run_until_complete(
                  self.loop.sock_recv_into(sock, bytearray())
              )
          with self.assertRaises(ValueError):
              self.loop.run_until_complete(self.loop.sock_accept(sock))
  
      # test in non-blocking mode
      sock.setblocking(False)
      self.loop.run_until_complete(
          self.loop.sock_connect(sock, httpd.address)
      )
      self.loop.run_until_complete(
          self.loop.sock_sendall(sock, b"GET / HTTP/1.0\r\n\r\n")
      )
      data = self.loop.run_until_complete(
          self.loop.sock_recv(sock, 1024)
      )
      # consume data
      self.loop.run_until_complete(self.loop.sock_recv(sock, 1024))
      sock.close()
      self.assertTrue(data.startswith(b"HTTP/1.0 200 OK"))
  
imports: import socket
  import asyncio
  import sys
  import unittest
  from asyncio import proactor_events
  from itertools import cycle, islice
  from unittest.mock import Mock
  from test.test_asyncio import utils
  from test import support
  from test.support import socket_helper
label_desc: Use image node_id 4 for calling the BaseSockTestsMixin obj's underlying member method code with example usage: obj._basetest_sock_client_ops(httpd, sock) without return types