'Test that AccountValidationError is thrown if incorrect values are supplied.'

def test_update_error_validating(self):

    with self.assertRaises(AccountValidationError):
        update_account_settings(self.user, {'username': 'not_allowed'})
    with self.assertRaises(AccountValidationError):
        update_account_settings(self.user, {'gender': 'undecided'})
    with self.assertRaises(AccountValidationError):
        update_account_settings(self.user, {'profile_image': {'has_image': 'not_allowed', 'image_url': 'not_allowed'}})
    with self.assertRaises(AccountValidationError):
        update_account_settings(self.user, {'language_proficiencies': 'not_a_list'})
    with self.assertRaises(AccountValidationError):
        update_account_settings(self.user, {'language_proficiencies': [{}]})
    with self.assertRaises(AccountValidationError):
        update_account_settings(self.user, {'account_privacy': ''})
