# File lib/shoulda/active_record/macros.rb, line 215 215: def should_ensure_length_is(attribute, length, opts = {}) 216: message = get_options!([opts], :message) 217: matcher = ensure_length_of(attribute). 218: is_equal_to(length). 219: with_message(message) 220: 221: should matcher.description do 222: assert_accepts matcher, subject 223: end 224: end