lib/inspec/profile.rb in inspec-1.4.0 vs lib/inspec/profile.rb in inspec-1.4.1

- old
+ new

@@ -58,17 +58,18 @@ @controls = options[:controls] || [] @writable = options[:writable] || false @profile_id = options[:id] @cache = options[:cache] || Cache.new @backend = options[:backend] || Inspec::Backend.create(options) + @attr_values = options[:attributes] @source_reader = source_reader @tests_collected = false @libraries_loaded = false Metadata.finalize(@source_reader.metadata, @profile_id) @runner_context = options[:profile_context] || - Inspec::ProfileContext.for_profile(self, @backend, options[:attributes]) + Inspec::ProfileContext.for_profile(self, @backend, @attr_values) end def name metadata.params[:name] end @@ -348,10 +349,10 @@ res.vendor(metadata.dependencies) Inspec::Lockfile.from_dependency_set(res) end def load_dependencies - Inspec::DependencySet.from_lockfile(lockfile, cwd, @cache, @backend) + Inspec::DependencySet.from_lockfile(lockfile, cwd, @cache, @backend, { attributes: @attr_values }) end private # Create an archive name for this profile and an additional options