mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
DEV: Reduce repeated code in discourse_plugin_registry (#9705)
Use a helper method to simplify creating a new register. Previously this would require creating lots of different methods manually, and adding every register to the clear/reset functions
This commit is contained in:
@@ -188,7 +188,7 @@ RSpec.configure do |config|
|
||||
# Ugly, but needed until we have a user creator
|
||||
User.skip_callback(:create, :after, :ensure_in_trust_level_group)
|
||||
|
||||
DiscoursePluginRegistry.clear if ENV['LOAD_PLUGINS'] != "1"
|
||||
DiscoursePluginRegistry.reset! if ENV['LOAD_PLUGINS'] != "1"
|
||||
Discourse.current_user_provider = TestCurrentUserProvider
|
||||
|
||||
SiteSetting.refresh!
|
||||
|
||||
Reference in New Issue
Block a user