aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/test_test.rb
diff options
context:
space:
mode:
authorSantiago Pastorino <santiago@wyeworks.com>2010-08-14 02:13:00 -0300
committerSantiago Pastorino <santiago@wyeworks.com>2010-08-14 04:12:33 -0300
commitb451de0d6de4df6bc66b274cec73b919f823d5ae (patch)
treef252c4143a0adb3be7d36d543282539cca0fb971 /activesupport/test/test_test.rb
parent1590377886820e00b1a786616518a32f3b61ec0f (diff)
downloadrails-b451de0d6de4df6bc66b274cec73b919f823d5ae.tar.gz
rails-b451de0d6de4df6bc66b274cec73b919f823d5ae.tar.bz2
rails-b451de0d6de4df6bc66b274cec73b919f823d5ae.zip
Deletes trailing whitespaces (over text files only find * -type f -exec sed 's/[ \t]*$//' -i {} \;)
Diffstat (limited to 'activesupport/test/test_test.rb')
-rw-r--r--activesupport/test/test_test.rb20
1 files changed, 10 insertions, 10 deletions
diff --git a/activesupport/test/test_test.rb b/activesupport/test/test_test.rb
index 633d3b212b..cdaf63961a 100644
--- a/activesupport/test/test_test.rb
+++ b/activesupport/test/test_test.rb
@@ -89,19 +89,19 @@ end
class AssertBlankTest < ActiveSupport::TestCase
BLANK = [ EmptyTrue.new, nil, false, '', ' ', " \n\t \r ", [], {} ]
NOT_BLANK = [ EmptyFalse.new, Object.new, true, 0, 1, 'x', [nil], { nil => 0 } ]
-
+
def test_assert_blank_true
BLANK.each { |v| assert_blank v }
end
-
+
def test_assert_blank_false
NOT_BLANK.each { |v|
- begin
+ begin
assert_blank v
fail 'should not get to here'
rescue Exception => e
- assert_match(/is not blank/, e.message)
- end
+ assert_match(/is not blank/, e.message)
+ end
}
end
end
@@ -109,19 +109,19 @@ end
class AssertPresentTest < ActiveSupport::TestCase
BLANK = [ EmptyTrue.new, nil, false, '', ' ', " \n\t \r ", [], {} ]
NOT_BLANK = [ EmptyFalse.new, Object.new, true, 0, 1, 'x', [nil], { nil => 0 } ]
-
+
def test_assert_blank_true
NOT_BLANK.each { |v| assert_present v }
end
-
+
def test_assert_blank_false
BLANK.each { |v|
- begin
+ begin
assert_present v
fail 'should not get to here'
rescue Exception => e
- assert_match(/is blank/, e.message)
- end
+ assert_match(/is blank/, e.message)
+ end
}
end
end