Sha256: b007764b8b4a68fb11158873887887e160f4f6c54a38d2a48b3b098a50540fe3

Contents?: true

Size: 391 Bytes

Versions: 2

Compression:

Stored size: 391 Bytes

Contents

# -*- encoding: utf-8 -*-

require 'aequitas/rule/absence'

module Aequitas
  class Rule
    class Absence
      class Blank < Absence

        def valid?(resource)
          Aequitas.blank?(attribute_value(resource))
        end

        def violation_type(resource)
          :not_blank
        end

      end # class Blank
    end # class Absence
  end # class Rule
end # module Aequitas

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
aequitas-0.0.2 lib/aequitas/rule/absence/blank.rb
aequitas-0.0.1 lib/aequitas/rule/absence/blank.rb