'Adds a list of users (either usernames or email addresses) to the currently selected cohort.'

def add_students_to_selected_cohort(self, users):

    textinput = self.q(css=self._bounded_selector('#cohort-management-group-add-students')).results[0]
    for user in users:
        textinput.send_keys(user)
        textinput.send_keys(',')
    self.q(css=self._bounded_selector('div.cohort-management-group-add    .action-primary')).first.click()
    self.wait_for((lambda : ('added    to    this    cohort' in self.get_cohort_confirmation_messages(wait_for_messages=True)[0])), 'Student(s)    added    confirmation    message.')
