code: def test_async_ssh_session(self):
      pkey = pkg_resources.resource_filename("mockssh", "server-key")
      data_folder = pkg_resources.resource_filename(__name__, "data")
      users = {
          "mockuser": pkey,
      }
      scores = {}
      mutex = Lock()
  
      config = {
          "workingdir": data_folder,
          "n_parallel": 2,
          "resource": "node",
          "proposer": "random",
          "script": os.path.join(
              data_folder, "script", "rosenbrock_hpo.py"
          ),
          "n_samples": 10,
          "random_seed": 10,
          "parameter_config": [
              {"name": "x", "type": "float", "range": [-5, 5]},
              {"name": "y", "type": "float", "range": [-5, 5]},
          ],
          "runtime_args": {
              "prescript": "export CUDA_VISIBLE_DEVICES=-1",
              "postscript": "echo $CUDA_VISIBLE_DEVICES",
              "overwrite": "true",
          },
          "resource_args": {"async_run": "true", "async_reconnect": 1},
      }
      m = rp.RandomProposer(config)
  
      def callback_fun(score, jid):
          mutex.acquire()
          scores[jid] = score
          mutex.release()
  
      with mockssh.Server(users) as server1, mockssh.Server(
          users
      ) as server2:
          mngr = SSHResourceManager(
              None,
              config["n_parallel"],
              auppath=data_folder,
              async_reconnect=1,
              async_run=True,
          )
          mngr.mapping[1] = (
              "mockuser@127.0.0.1:" + str(server1.port) + " " + pkey
          )
          mngr.mapping[2] = (
              "mockuser@127.0.0.1:" + str(server2.port) + " " + pkey
          )
  
          for i in range(0, config["n_samples"], 2):
              proposal = m.get()
              job1 = Job(
                  config["script"],
                  BasicConfig(**proposal),
                  config["workingdir"],
              )
              job1.jid = i
              mngr.run(job1, 1, None, callback_fun, overwrite=True)
  
              proposal = m.get()
              job2 = Job(
                  config["script"],
                  BasicConfig(**proposal),
                  config["workingdir"],
              )
              job2.jid = i + 1
              mngr.run(job2, 2, None, callback_fun, overwrite=True)
  
          mngr.executor.shutdown(wait=True)
  
      for key in scores:
          self.assertTrue(scores[key] != "ERROR")
  
imports: import unittest
  import mockssh
  import tempfile
  import pdb
  from shutil import copyfile
  from time import sleep
  from six import PY2
  import pkg_resources
  from aup.EE.Resource.SSHResourceManager import *
  from aup.EE.Job import Job
  from aup import BasicConfig
  from aup.Proposer import RandomProposer
  from aup.utils import get_default_connector
  from threading import Lock
label_desc: Use image node_id 2 for calling the AsyncSSHResourceManagerTestCase obj's underlying member method code with example usage: obj.test_async_ssh_session() without return types