Method: Inspec::Metadata.from_file
- Defined in:
- lib/inspec/metadata.rb
.from_file(path, profile_id, logger = nil) ⇒ Object
215 216 217 218 219 220 221 222 223 |
# File 'lib/inspec/metadata.rb', line 215 def self.from_file(path, profile_id, logger = nil) unless File.file?(path) logger ||= Logger.new(nil) logger.error "Can't find metadata file #{path}" return nil end from_ref(File.basename(path), File.read(path), profile_id, logger) end |