Return the storage backend, setting its loaded data to the ``data`` argument. This method avoids the storage ``_get`` method from getting called so that other parts of the storage backend can be tested independent of the message retrieval logic.
(self, data=None)
| 65 | return HttpResponse() |
| 66 | |
| 67 | def get_storage(self, data=None): |
| 68 | """ |
| 69 | Return the storage backend, setting its loaded data to the ``data`` |
| 70 | argument. |
| 71 | |
| 72 | This method avoids the storage ``_get`` method from getting called so |
| 73 | that other parts of the storage backend can be tested independent of |
| 74 | the message retrieval logic. |
| 75 | """ |
| 76 | storage = self.storage_class(self.get_request()) |
| 77 | storage._loaded_data = data or [] |
| 78 | return storage |
| 79 | |
| 80 | def test_repr(self): |
| 81 | request = self.get_request() |