7 lines
199 B
Python
7 lines
199 B
Python
from unittest.mock import patch
|
|
|
|
|
|
def get_plugin_patcher(plugin_class):
|
|
"""Return a context manager to patch a Plugin init."""
|
|
return patch.object(plugin_class, "__init__", lambda bot: None)
|