support/ruby/collins-client/lib/collins/util.rb
# Require that a guard condition passes
#
# Simply checks that the guard is truthy, and throws an error otherwise
# @see #require_non_empty
Require that a guard condition passes
Simply checks that the guard is truthy, and throws an error otherwise
Require that a guard condition passes Simply checks that the guard is truthy and throws an error otherwise
def require_that guard, message, return_guard = false
      if not guard then
        raise ExpectationFailedError.new(message)
      end
      if return_guard == true then
        guard
      elsif return_guard != false then
        return_guard
      end
    end
def require_that guard , message , return_guard = false if not guard then raise ExpectationFailedError . new ( message ) end if return_guard == true then guard elsif return_guard != false then return_guard end end
Require that a guard condition passes
Simply checks that the guard is truthy, and throws an error otherwise
Require that a guard condition passes Simply checks that the guard is truthy and throws an error otherwise
guard
message
return_guard
see
None