File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -106,6 +106,8 @@ def register_plugin(self, plugin):
106
106
except RegistrationError :
107
107
pass
108
108
109
+ return plugin
110
+
109
111
def unregister_plugin (self , plugin ):
110
112
"""
111
113
Unregisters the given plugin(s).
Original file line number Diff line number Diff line change @@ -1092,6 +1092,13 @@ def test_plugin_translatable_content_getter_setter(self):
1092
1092
# double check through the getter
1093
1093
self .assertEqual ({'body' : "It works!" }, plugin .get_translatable_content ())
1094
1094
1095
+ def test_plugin_pool_register_returns_plugin_class (self ):
1096
+ @plugin_pool .register_plugin
1097
+ class DecoratorTestPlugin (CMSPluginBase ):
1098
+ render_plugin = False
1099
+ name = "Test Plugin"
1100
+ self .assertIsNotNone (DecoratorTestPlugin )
1101
+
1095
1102
1096
1103
class FileSystemPluginTests (PluginsTestBaseCase ):
1097
1104
def setUp (self ):
You can’t perform that action at this time.
0 commit comments