              response = self.unscoped_view(request)
              assert response.status_code == 200
  
      def test_get_cache_key_returns_correct_key_if_user_is_authenticated(self):
          class DummyView(object):
              throttle_scope = 'user'
  
          request = Request(HttpRequest())
          user = User.objects.create(username='test')
          force_authenticate(request, user)
 
</s> remove         request = factory.patch('/{0}'.format(obj.pk), {'number_value': 101}, format='json')
 </s> add         request = factory.patch('/{}'.format(obj.pk), {'number_value': 101}, format='json') </s> remove         request = factory.patch('/{0}'.format(obj.pk), {'number_value': 98}, format='json')
 </s> add         request = factory.patch('/{}'.format(obj.pk), {'number_value': 98}, format='json') </s> remove         assert response.content == six.b('')
 </s> add         assert response.content == b'' </s> remove         request = factory.put('/{0}'.format(filtered_out_pk), data, format='json')
 </s> add         request = factory.put('/{}'.format(filtered_out_pk), data, format='json') </s> remove class BaseTokenAuthTests(object):
 </s> add class BaseTokenAuthTests:
        class DummyView:
              response = self.unscoped_view(request)
              assert response.status_code == 200
  
      def test_get_cache_key_returns_correct_key_if_user_is_authenticated(self):
        class DummyView:
              throttle_scope = 'user'
  
          request = Request(HttpRequest())
          user = User.objects.create(username='test')
          force_authenticate(request, user)
keep keep keep keep replace keep keep keep keep keep
 Dropped Python 2 compatibility. (#6615)

Thanks to Jon Dufresne (@jdufresne) for review.

Co-authored-by: Asif Saif Uddin <auvipy@gmail.com>
Co-authored-by: Rizwan Mansuri <Rizwan@webbyfox.com> 
tests/test_throttling.py