Class: Inspec::MockProvider
- Inherits:
- 
      FileProvider
      
        - Object
- FileProvider
- Inspec::MockProvider
 
- Defined in:
- lib/inspec/file_provider.rb
Instance Attribute Summary collapse
- 
  
    
      #files  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    Returns the value of attribute files. 
Instance Method Summary collapse
- 
  
    
      #initialize(path)  ⇒ MockProvider 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    A new instance of MockProvider. 
- #read(file) ⇒ Object
Methods inherited from FileProvider
#binread, for_path, #relative_provider
Constructor Details
#initialize(path) ⇒ MockProvider
Returns a new instance of MockProvider.
| 59 60 61 62 | # File 'lib/inspec/file_provider.rb', line 59 def initialize(path) @data = path[:mock] @files = @data.keys end | 
Instance Attribute Details
#files ⇒ Object (readonly)
Returns the value of attribute files.
| 58 59 60 | # File 'lib/inspec/file_provider.rb', line 58 def files @files end | 
Instance Method Details
#read(file) ⇒ Object
| 64 65 66 | # File 'lib/inspec/file_provider.rb', line 64 def read(file) @data[file] end |