def test_check_has_perm(self):
        vid = VideoFactory(creator=self.user)
        u = UserFactory()
        add_permission(u, Video, 'change_video')
        check_media_permissions(vid, u, 'change')
Return the most obvious language according the request
dataset/ETHPy150Open mozilla/kitsune/kitsune/gallery/tests/test_utils.py/CheckPermissionsTestCase.test_check_has_perm--crossover with--dataset/ETHPy150Open divio/django-cms/cms/utils/__init__.py/get_language_from_request