Skip to content

Commit 3388e54

Browse files
committed
Fix post-only throttle direct test
1 parent 6867cd5 commit 3388e54

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

users/tests/test_auth_throttling.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
from django.conf import settings
44
from django.core.cache import cache
55
from django.test import TestCase, override_settings
6+
from rest_framework.permissions import AllowAny
67
from rest_framework.response import Response
78
from rest_framework.test import APIClient, APIRequestFactory
89
from rest_framework.views import APIView
@@ -22,6 +23,7 @@ def throttle_settings(**rates):
2223

2324

2425
class DummyPostOnlyThrottleView(APIView):
26+
permission_classes = [AllowAny]
2527
throttle_classes = [PostOnlyScopedRateThrottle]
2628
throttle_scope = "auth_register"
2729

0 commit comments

Comments
 (0)