MCPcopy Index your code
hub / github.com/encode/django-rest-framework / test_get_caching

Method test_get_caching

tests/test_renderers.py:444–453  ·  view source on GitHub ↗

Test caching of GET requests

(self)

Source from the content-addressed store, hash-verified

442 assert cached_response.status_code == response.status_code
443
444 def test_get_caching(self):
445 """
446 Test caching of GET requests
447 """
448 response = self.client.get('/cache')
449 cache.set('key', response)
450 cached_response = cache.get('key')
451 assert isinstance(cached_response, Response)
452 assert cached_response.content == response.content
453 assert cached_response.status_code == response.status_code
454
455
456class TestJSONIndentationStyles:

Callers

nothing calls this directly

Calls 2

setMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected