def setup_test_environment():
    Template.original_render = Template.render
    Template.render = instrumented_test_render

    mail.original_SMTPConnection = mail.SMTPConnection
    mail.SMTPConnection = TestSMTPConnection

    mail.outbox = []

    deactivate()
Disconnect handlers. 
dataset/ETHPy150Open CollabQ/CollabQ/vendor/django/test/utils.py/setup_test_environment--crossover with--dataset/ETHPy150Open zoofIO/flexx/flexx/event/_hasevents.py/HasEvents.disconnect