+page_finished_rendering_to_string = Signal(providing_args=['string'])
+
+
+def replace_sender_response(sender, response):
+ """Helper function to swap in a new response."""
+ def render_to_response(self, *args, **kwargs):
+ return response
+ sender.actually_render_to_response = render_to_response
\ No newline at end of file