'Fill the database with a certain number of subjects and clients.'

def _FillDatabase(self, nsubjects, nclients, max_attributes=3):

    self.rand = random.Random(0)
    self.test_name = 'fill'
    self.AddResult(self.test_name, 0, self.steps, data_store.DB.Size(), 0, 0, 0, 0)
    subjects = dict.fromkeys(xrange(nsubjects))
    value = os.urandom(100)
    clients = [self._GenerateRandomClient() for _ in xrange(nclients)]
    for i in subjects:
        client = self.rand.choice(clients)
        self._AddNewSubject(client, subjects, i, value, max_attributes)
    data_store.DB.Flush()
    return subjects
