'Verify that we can use emails to identify users.
Expect unknown email address not associated with an account to be preassigned.
Expect unknown user (neither an email address nor a username) to not be added.'

def test_emails(self):

    valid_email_no_account = 'unknown_user@example.com'
    unknown_user = 'unknown'
    response_dict = self.request_add_users_to_cohort(','.join([self.cohort1_users[0].email, self.cohort2_users[0].email, self.cohortless_users[0].email, valid_email_no_account, unknown_user]), self.cohort1, self.course)
    self.verify_added_users_to_cohort(response_dict, self.cohort1, self.course, expected_added=[self.cohortless_users[0]], expected_changed=[(self.cohort2_users[0], self.cohort2.name)], expected_present=[(self.cohort1_users[0], self.cohort1_users[0].email)], expected_preassigned=[valid_email_no_account], expected_unknown=[unknown_user], expected_invalid=[])
