Class: Fauxhai::Mocker
- Inherits:
-
Object
- Object
- Fauxhai::Mocker
- Defined in:
- lib/fauxhai/mocker.rb
Constant Summary collapse
- RAW_BASE =
The base URL for the GitHub project (raw)
'https://raw.githubusercontent.com/chefspec/fauxhai/master'.freeze
- PLATFORM_LIST_MESSAGE =
A message about where to find a list of platforms
'A list of available platforms is available at https://github.com/chefspec/fauxhai/blob/master/PLATFORMS.md'.freeze
Instance Attribute Summary collapse
-
#data ⇒ Hash
readonly
The raw ohai data for the given Mock.
Instance Method Summary collapse
-
#initialize(options = {}) {|@data| ... } ⇒ Mocker
constructor
Create a new Ohai Mock with fauxhai.
Constructor Details
#initialize(options = {}) {|@data| ... } ⇒ Mocker
Create a new Ohai Mock with fauxhai.
28 29 30 31 32 33 34 35 |
# File 'lib/fauxhai/mocker.rb', line 28 def initialize( = {}, &override_attributes) @options = { github_fetching: true }.merge() @data = fauxhai_data yield(@data) if block_given? @data end |
Instance Attribute Details
#data ⇒ Hash (readonly)
Returns The raw ohai data for the given Mock.
14 15 16 |
# File 'lib/fauxhai/mocker.rb', line 14 def data @data end |