def test_get_object(self, user: User, request_factory: RequestFactory): view = UserUpdateView() request = request_factory.get("/fake-url/") request.user = user view.request = request assert view.get_object() == user
def test_get_object(self, user: settings.AUTH_USER_MODEL, request_factory: RequestFactory): view = UserUpdateView() request = request_factory.get("/fake-url/") request.user = user view.request = request assert view.get_object() == user