add handler cleanup functionality
When hubs are created and deleted, the handlers added to the logger are not removed. This adds a class that, when deleted, triggers the removal of those handlers from the root logger. This prevents a resource leak in test code.