mirror of
https://github.com/ThrowTheSwitch/CMock.git
synced 2026-08-01 16:57:48 +00:00
- fixed the other place that had the same problem for 1.8.7's lack of define_singleton_method
This commit is contained in:
@@ -20,8 +20,13 @@ describe CMockPluginManager, "Verify CMockPluginManager Module" do
|
||||
:enforce_strict_ordering => false,
|
||||
:ignore => :args_and_calls
|
||||
)
|
||||
@config.define_singleton_method( :plugins ){ @plugins || [] }
|
||||
@config.define_singleton_method( :plugins= ){ |val| @plugins = val }
|
||||
|
||||
#if (RUBY_VERSION.split('.')[0].to_i >= 2)
|
||||
# @config.define_singleton_method( :plugins ){ @plugins || [] }
|
||||
# @config.define_singleton_method( :plugins= ){ |val| @plugins = val }
|
||||
#else
|
||||
eval "class << @config\ndef plugins\n@plugins||[]\nend\ndef plugins=(val)\n@plugins=val\nend\nend\n"
|
||||
#end
|
||||
end
|
||||
|
||||
after do
|
||||
|
||||
Reference in New Issue
Block a user