'Tests that adding to creator group fails if user is not authenticated'

def test_add_user_not_authenticated(self):

    with mock.patch.dict('django.conf.settings.FEATURES', {'DISABLE_COURSE_CREATION': False, 'ENABLE_CREATOR_GROUP': True}):
        anonymous_user = AnonymousUser()
        role = CourseCreatorRole()
        add_users(self.admin, role, anonymous_user)
        self.assertFalse(user_has_role(anonymous_user, role))
