def method_missing(method, *args)
      if method.to_s.starts_with? "*"
        condition_name = method.to_s.split("*")[1].to_sym
        conditions = self.class.scram_conditions
        if conditions && !conditions[condition_name].nil?
          return conditions[condition_name].call(self)
        end
      end
      super
    end
def method_missing(method, *args)
      if method.to_s.starts_with? "*"
        condition_name = method.to_s.split("*")[1].to_sym
        conditions = self.class.scram_conditions
        if conditions && !conditions[condition_name].nil?
          return conditions[condition_name].call(self)
        end
      end
      super
    end
def method_missing ( method , * args ) if method . to_s . starts_with? "*" condition_name = method . to_s . split ( "*" ) [ 1 ] . to_sym conditions = self . class . scram_conditions if conditions && ! conditions [ condition_name ] . nil? return conditions [ condition_name ] . call ( self ) end end super end
Methods starting with an asterisk are tested for DSL defined conditions
Methods starting with an asterisk are tested for DSL defined conditions