class Feature::Operation::And

Public Class Methods

call(entity, attr_name, expected) click to toggle source
# File lib/toggles/feature/operation/and.rb, line 4
def self.call(entity, attr_name, expected)
  expected.all? do |operation, value|
    if OPERATIONS.include? operation.to_sym
      OPERATIONS[operation.to_sym].call(entity, attr_name, value)
    else
      Operation::Attribute.call(entity, operation, value)
    end
  end
end