docs: def expect_list(connection, regexp_list, timeout=10):
          '''
          Expect a list of expressions
  
          @param connection: Connection to the host
          @type connection: L{Connection}
  
          @param regexp_list: regular expressions and associated return values
          @type regexp_list: list of (regexp, return value)
  
          @param timeout: timeout for performing expect operation
          @type timeout: int
  
          @return: propper return value from regexp_list
          @rtype: return value
  
          @raises ExpectFailed
          '''
          result = ""
          count = 0
          while count < timeout:
              try:
                  recv_part = connection.channel.recv(32768).decode()
                  logging.getLogger('stitches.expect').debug("RCV: " + recv_part)
                  if connection.output_shell:
                      sys.stdout.write(recv_part)
                  result += recv_part
              except socket.timeout:
                  # socket.timeout here means 'no more data'
                  pass
  
              for (regexp, retvalue) in regexp_list:
                  # search for the first matching regexp and return desired value
                  if re.match(regexp, result):
                      return retvalue
              time.sleep(1)
              count += 1
          raise ExpectFailed(result)