added rest of specs for matcher

This commit is contained in:
Adam Meehan
2008-07-26 07:49:26 +10:00
parent 766e0f3bac
commit 7fd251dddf
2 changed files with 114 additions and 38 deletions

View File

@@ -100,6 +100,10 @@ module Spec
@last_failure = "value #{value} to not have error matching #{match.inspect}" unless pass
pass
end
def format_value(value)
value.strftime(ActiveRecord::Errors.date_time_error_value_formats[options[:type]])
end
end
def validate_date(attribute, options={})