Fixed #21476 -- Cache tests make an incorrect use of `HttpRequest`

Using `django.test.client.RequestFactory` solves the problem and cleans up all
the `get_request` mess.