Method: Inspec::Requirement#profile

Defined in:
lib/inspec/dependencies/requirement.rb

#profileObject

load the profile for the requirement



117
118
119
120
121
122
123
124
125
126
127
128
# File 'lib/inspec/dependencies/requirement.rb', line 117

def profile
  return @profile unless @profile.nil?
  opts = @opts.dup
  opts[:backend] = @backend
  if !@dependencies.nil? && !@dependencies.empty?
    opts[:dependencies] = Inspec::DependencySet.from_array(@dependencies, @cwd, @cache, @backend)
  end
  opts[:profile_name] = @name
  opts[:parent_profile] = @parent_profile
  @profile = Inspec::Profile.for_fetcher(fetcher, opts)
  @profile
end