mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 19:33:44 +08:00
DEV: Further refine development reload for plugin files (#22141)
Followup f3afc8bf85
to better
exclude all spec files including PageObject files.
This commit is contained in:
parent
d548231475
commit
3802d0de9d
|
@ -21,7 +21,8 @@ if Rails.env.development? && !Rails.configuration.cache_classes && Discourse.run
|
|||
not_autoloaded =
|
||||
files.filter_map do |file|
|
||||
autoloaded = Rails.autoloaders.main.__autoloads.key? file
|
||||
if !autoloaded && !file.end_with?("spec.rb")
|
||||
|
||||
if !autoloaded && !file.match(%r{/spec/})
|
||||
Pathname.new(file).relative_path_from(Rails.root)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user