Method: Inspec::Requirement#to_hash
- Defined in:
- lib/inspec/dependencies/requirement.rb
#to_hash ⇒ Object
86 87 88 89 90 91 92 93 94 95 96 97 98 |
# File 'lib/inspec/dependencies/requirement.rb', line 86 def to_hash h = { "name" => name, "resolved_source" => resolved_source, "version_constraints" => version_constraints, } unless dependencies.empty? h["dependencies"] = dependencies.map(&:to_hash) end h end |