diff options
author | Florent Guilleux <florent2@gmail.com> | 2012-12-01 13:22:49 -0500 |
---|---|---|
committer | Florent Guilleux <florent2@gmail.com> | 2012-12-01 13:22:49 -0500 |
commit | 8dc4041a9b2fb0e8bc2bcb72ab93adb8722e62cd (patch) | |
tree | d3c21858cb1a7fae8339b4542b200d59dc9ec815 /activemodel/test | |
parent | 90c887fa7d0c454b7533e208daefc342dea4d5f3 (diff) | |
download | rails-8dc4041a9b2fb0e8bc2bcb72ab93adb8722e62cd.tar.gz rails-8dc4041a9b2fb0e8bc2bcb72ab93adb8722e62cd.tar.bz2 rails-8dc4041a9b2fb0e8bc2bcb72ab93adb8722e62cd.zip |
Revert "Remove trailing whitespaces"
This reverts commit 90c887fa7d0c454b7533e208daefc342dea4d5f3.
Diffstat (limited to 'activemodel/test')
-rw-r--r-- | activemodel/test/cases/validations/format_validation_test.rb | 4 | ||||
-rw-r--r-- | activemodel/test/models/oauthed_user.rb | 2 | ||||
-rw-r--r-- | activemodel/test/models/user.rb | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/activemodel/test/cases/validations/format_validation_test.rb b/activemodel/test/cases/validations/format_validation_test.rb index 1adb3cea49..308a3c6cef 100644 --- a/activemodel/test/cases/validations/format_validation_test.rb +++ b/activemodel/test/cases/validations/format_validation_test.rb @@ -68,11 +68,11 @@ class PresenceValidationTest < ActiveModel::TestCase assert t.invalid? assert_equal ["can't be Invalid title"], t.errors[:title] end - + def test_validate_format_of_with_multiline_regexp_should_raise_error assert_raise(ArgumentError) { Topic.validates_format_of(:title, :with => /^Valid Title$/) } end - + def test_validate_format_of_with_multiline_regexp_and_option assert_nothing_raised(ArgumentError) do Topic.validates_format_of(:title, :with => /^Valid Title$/, :multiline => true) diff --git a/activemodel/test/models/oauthed_user.rb b/activemodel/test/models/oauthed_user.rb index c6923c4f58..9750bc19d4 100644 --- a/activemodel/test/models/oauthed_user.rb +++ b/activemodel/test/models/oauthed_user.rb @@ -2,7 +2,7 @@ class OauthedUser extend ActiveModel::Callbacks include ActiveModel::Validations include ActiveModel::SecurePassword - + define_model_callbacks :create has_secure_password(validations: false) diff --git a/activemodel/test/models/user.rb b/activemodel/test/models/user.rb index c38881063e..4b11df12bf 100644 --- a/activemodel/test/models/user.rb +++ b/activemodel/test/models/user.rb @@ -2,7 +2,7 @@ class User extend ActiveModel::Callbacks include ActiveModel::Validations include ActiveModel::SecurePassword - + define_model_callbacks :create has_secure_password |