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



45
46
47
48
49
50
51
# File 'lib/rspec-puppet/errors.rb', line 45

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