Module: CommandServiceObject::CheckHelper

Included in:
CaseBase
Defined in:
lib/command_service_object/helpers/check_helper.rb

Instance Method Summary collapse

Instance Method Details

#check!(message, &block) ⇒ Object



3
4
5
6
7
# File 'lib/command_service_object/helpers/check_helper.rb', line 3

def check!(message, &block)
  raise "No block given" unless block_given?

  fail!(message) if block.call
end