def add_check(data, type, keywords, options = {})
      t = type.to_sym

      fail Exceptions::UnknownCheckType, "Unknown check type \":#{t}\" given. Did you register it in advance?" unless comparators.key?(t)
      opts = {
        exceptions: [],
        tag: ''
      }.merge options

      sample = Sample.new(data, keywords, opts[:exceptions], opts[:tag])
      strategy_klass = comparators[t]
      check = Check.new(strategy_klass, sample)

      @cache[:checks].add check
    end
def add_check(data, type, keywords, options = {})
      t = type.to_sym

      fail Exceptions::UnknownCheckType, "Unknown check type \":#{t}\" given. Did you register it in advance?" unless comparators.key?(t)
      opts = {
        exceptions: [],
        tag: ''
      }.merge options

      sample = Sample.new(data, keywords, opts[:exceptions], opts[:tag])
      strategy_klass = comparators[t]
      check = Check.new(strategy_klass, sample)

      @cache[:checks].add check
    end
Add a check to test against

 @param [Array] data
   the data which should be used as check, will be passed to the concrete comparator strategy

 @param [Symbol] type
   the comparator strategy (needs to be registered first)

 @param [Array] keywords
   what to look for in the data, will be passed to the concrete comparator strategy

 @param [Hash] options
   exception, should not be considered as match

 @option options [Hash] exceptions
   the exceptions from keywords

 @option options [String] tag
   a tag to identify the check

 @raise [Exceptions::UnknownCheckType]
   if a unknown strategy is given (needs to be registered first)