Method: Inspec::Resources::WMI#initialize
- Defined in:
- lib/resources/wmi.rb
#initialize(wmiclass = nil, opts = nil) ⇒ WMI
27 28 29 30 31 32 33 34 35 36 |
# File 'lib/resources/wmi.rb', line 27 def initialize(wmiclass = nil, opts = nil) = opts || {} # if wmiclass is not a hash, we have to handle deprecation behavior if wmiclass.is_a?(Hash) .merge!(wmiclass) else warn '[DEPRECATION] `wmi(\'wmiclass\')` is deprecated. Please use `wmi({class: \'wmiclass\'})` instead.' [:class] = wmiclass end end |