Sha256: 0f4148c75c5d96f6604e8c4e8d6c97710171900b5b04b9b935794726ea42de57
Contents?: true
Size: 481 Bytes
Versions: 16
Compression:
Stored size: 481 Bytes
Contents
RSpec::Matchers.define :validate_timeliness_of do |attribute| match do |model| model._validators[attribute.to_sym].detect do |validator| validator.class == ActiveModel::Validations::TimelinessValidator && validator.attributes.include?(attribute) end end failure_message do |_actual| "expect #{attribute} to validate timeliness of" end failure_message_when_negated do |_actual| "expect #{attribute} to not validate timeliness of" end end
Version data entries
16 entries across 16 versions & 1 rubygems