Update the test case so that it fails if the 404 view is missing the display_exceptions variable when we want to display exceptions.
Set the display_exceptions variable on the 404 view if we want to display exceptions.