'This tests running the hunt on some clients.'

def testHuntCollectionLogging(self):

    with implementation.GRRHunt.StartHunt(hunt_name=standard.GenericHunt.__name__, flow_runner_args=rdf_flows.FlowRunnerArgs(flow_name=flow_test_lib.DummyLogFlow.__name__), client_rate=0, token=self.token) as hunt:
        hunt.Run()
        hunt.Log('Log    from    the    hunt    itself')
    hunt_urn = hunt.urn
    self.AssignTasksToClients()
    self.RunHunt()
    hunt_logs = implementation.GRRHunt.LogCollectionForHID(hunt_urn, token=self.token)
    count = 0
    for log in hunt_logs:
        if log.client_id:
            self.assertTrue((log.client_id in self.client_ids))
            self.assertTrue((log.log_message in ['First', 'Second', 'Third', 'Fourth', 'Uno', 'Dos', 'Tres', 'Cuatro']))
            self.assertTrue((log.flow_name in [flow_test_lib.DummyLogFlow.__name__, flow_test_lib.DummyLogFlowChild.__name__]))
            self.assertTrue((str(hunt_urn) in str(log.urn)))
        else:
            self.assertEqual(log.log_message, 'Log    from    the    hunt    itself')
            self.assertEqual(log.flow_name, standard.GenericHunt.__name__)
            self.assertEqual(log.urn, hunt_urn)
        count += 1
    self.assertEqual(count, ((8 * len(self.client_ids)) + 1))
