pdksync_heads/master-0-g7827fc2
This commit is contained in:
@@ -42,6 +42,8 @@ RSpec.configure do |c|
|
||||
end
|
||||
end
|
||||
|
||||
# Ensures that a module is defined
|
||||
# @param module_name Name of the module
|
||||
def ensure_module_defined(module_name)
|
||||
module_name.split('::').reduce(Object) do |last_module, next_module|
|
||||
last_module.const_set(next_module, Module.new) unless last_module.const_defined?(next_module, false)
|
||||
|
||||
Reference in New Issue
Block a user