Sha256: 975e48009cfb8de9bebf1bae5d058d6a74dc6617b03a2dfa35f425ccd998e6b5
Contents?: true
Size: 348 Bytes
Versions: 8
Compression:
Stored size: 348 Bytes
Contents
RSpec::Matchers.define :have_error_on do |*args| match do |model| field = args.dup.shift error_messages = args model.valid? model.errors[field].any? end end RSpec::Matchers.define :have_index do |index_name| match do |model| model.collection.index_information.detect { |index| index[0] == index_name }.present? end end
Version data entries
8 entries across 8 versions & 2 rubygems