From de777764da0c0e9fe66d0bb76317679be964588b Mon Sep 17 00:00:00 2001
From: Eliot Berriot <contact@eliotberriot.com>
Date: Sat, 31 Mar 2018 18:39:54 +0200
Subject: [PATCH] Fake_request fixture for django requests

---
 api/tests/conftest.py | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/api/tests/conftest.py b/api/tests/conftest.py
index 6d5e733120..d5bb565651 100644
--- a/api/tests/conftest.py
+++ b/api/tests/conftest.py
@@ -6,6 +6,8 @@ import tempfile
 
 from django.contrib.auth.models import AnonymousUser
 from django.core.cache import cache as django_cache
+from django.test import client
+
 from dynamic_preferences.registries import global_preferences_registry
 
 from rest_framework.test import APIClient
@@ -118,6 +120,11 @@ def api_request():
     return APIRequestFactory()
 
 
+@pytest.fixture
+def fake_request():
+    return client.RequestFactory()
+
+
 @pytest.fixture
 def activity_registry():
     r = record.registry
-- 
GitLab