``teardown_function`` in test_messaging.py already does this. Maybe make it a utility?