Sha256: 73ac147b7e4f2178c4c5dde284ffe00bd18519364d24cfb598d4fb7fdadd0fce
Contents?: true
Size: 590 Bytes
Versions: 14
Compression:
Stored size: 590 Bytes
Contents
# frozen_string_literal: true module RuboCop module Cop module Minitest # This cop enforces the test to use `assert_match` # instead of using `assert(matcher.match(string))`. # # @example # # bad # assert(matcher.match(string)) # assert(matcher.match(string), 'message') # # # good # assert_match(regex, string) # assert_match(matcher, string, 'message') # class AssertMatch < Base extend MinitestCopRule define_rule :assert, target_method: :match end end end end
Version data entries
14 entries across 14 versions & 1 rubygems