def teardown_test_environment():
 Template._render = Template._original_render
 del Template._original_render
 settings.EMAIL_BACKEND = mail._original_email_backend
 del mail._original_email_backend
 settings.ALLOWED_HOSTS = request._original_allowed_hosts
 del request._original_allowed_hosts
 del mail.outbox

def teardown_test_environment ( ) : Template . _render = Template . _original_render del Template . _original_render settings . EMAIL_BACKEND = mail . _original_email_backend del mail . _original_email_backend settings . ALLOWED_HOSTS = request . _original_allowed_hosts del request . _original_allowed_hosts del mail . outbox
this method is called by nose_runner when the tests all finish .