Sha256: 09796572d1b468724d6932c3f98db924cdabba0794e97643b5148eb473df2af4
Contents?: true
Size: 505 Bytes
Versions: 30
Compression:
Stored size: 505 Bytes
Contents
# frozen_string_literal: true module Cmdlet # Comparison helpers, eg. or, and, equal, not equal, less than, greater than etc. module Comparison # And: Return true if **all of** the given values are truthy. class And < Cmdlet::BaseCmdlet # # @param [Object] values - list of values (via *splat) to be checked via AND condition # @return [String] return true when every value is truthy def call(*values) values.all? { |value| value } end end end end
Version data entries
30 entries across 30 versions & 1 rubygems