summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2023-08-24 10:31:52 +0200
committerGitHub <noreply@github.com>2023-08-24 10:31:52 +0200
commit95b844915822daa41247ae56d2ccd5cf36c881e1 (patch)
tree106dc41ff44d96c1eb4f86eb07ed10c9ecea45d2
parent9942a3e49b801b59e10329d86cd8bf12f1716529 (diff)
Corrected AsyncRequestFactory's docstring.
All AsyncRequestFactory methods are still synchronous callables.
-rw-r--r--django/test/client.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/django/test/client.py b/django/test/client.py
index a0e6c66e06..eed2d4f828 100644
--- a/django/test/client.py
+++ b/django/test/client.py
@@ -623,8 +623,8 @@ class AsyncRequestFactory(RequestFactory):
testing. Usage:
rf = AsyncRequestFactory()
- get_request = await rf.get('/hello/')
- post_request = await rf.post('/submit/', {'foo': 'bar'})
+ get_request = rf.get("/hello/")
+ post_request = rf.post("/submit/", {"foo": "bar"})
Once you have a request object you can pass it to any view function,
including synchronous ones. The reason we have a separate class here is: