Exception: RSpec::Puppet::Errors::ProcMatchError

Inherits:
MatchError
  • Object
show all
Defined in:
lib/rspec-puppet/errors.rb

Instance Attribute Summary

Attributes inherited from MatchError

#actual, #expected, #negative, #param

Instance Method Summary collapse

Methods inherited from MatchError

#initialize, #to_s

Constructor Details

This class inherits a constructor from RSpec::Puppet::Errors::MatchError

Instance Method Details

#messageObject



37
38
39
40
41
42
43
# File 'lib/rspec-puppet/errors.rb', line 37

def message
  if negative == true
    "#{param} passed to the block would not return `#{expected.inspect}` but it did"
  else
    "#{param} passed to the block would return `#{expected.inspect}` but it is `#{actual.inspect}`"
  end
end