def GetClientURNsForHostnames(hostnames, token=None):

  index = aff4.FACTORY.Create(
      MAIN_INDEX, aff4_type="ClientIndex", mode="rw", object_exists=True,
      token=token)

  keywords = set()
  for hostname in hostnames:
    if hostname.startswith("host:"):
      keywords.add(hostname)
    else:
      keywords.add("host:%s" % hostname)
  results = index.ReadClientPostingLists(keywords)

  result = {}
  for keyword, hits in results.iteritems():
    result[keyword[len("host:"):]] = hits
  return result
Decorator to indicate a test should be skipped.
dataset/ETHPy150Open google/grr/grr/lib/client_index.py/GetClientURNsForHostnames--crossover with--dataset/ETHPy150Open enthought/traits/traits/testing/nose_tools.py/skip