Sha256: 60cc0f4b58b7600ba6b97f76166e35c31bfc17fbed3f9261889dade2c6751254
Contents?: true
Size: 528 Bytes
Versions: 28
Compression:
Stored size: 528 Bytes
Contents
# frozen_string_literal: true require_relative '../../puppet/confine/boolean' class Puppet::Confine::True < Puppet::Confine include Puppet::Confine::Boolean def passing_value true end def self.summarize(confines) confines.inject(0) { |count, confine| count + confine.summary } end def pass?(value) # Double negate, so we only get true or false. !!value end def message(value) "false value when expecting true" end def summary result.find_all { |v| v == true }.length end end
Version data entries
28 entries across 28 versions & 1 rubygems