aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/core_ext
diff options
context:
space:
mode:
authorSam Stephenson <sam@37signals.com>2007-01-15 22:02:11 +0000
committerSam Stephenson <sam@37signals.com>2007-01-15 22:02:11 +0000
commit312e6edf914a8b561feacac2486d97e7904472e5 (patch)
treeaa7f808afc3726c3170b269ef60c18f1e1e0c77f /activesupport/test/core_ext
parent521ca37c3e6c453f48ab1dd9225bde6ea3a0c9d6 (diff)
downloadrails-312e6edf914a8b561feacac2486d97e7904472e5.tar.gz
rails-312e6edf914a8b561feacac2486d97e7904472e5.tar.bz2
rails-312e6edf914a8b561feacac2486d97e7904472e5.zip
Fix that Dates couldn't be subtracted from Dates after [5940].
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5954 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activesupport/test/core_ext')
-rw-r--r--activesupport/test/core_ext/duration_test.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/activesupport/test/core_ext/duration_test.rb b/activesupport/test/core_ext/duration_test.rb
index 78fc999052..22950d8710 100644
--- a/activesupport/test/core_ext/duration_test.rb
+++ b/activesupport/test/core_ext/duration_test.rb
@@ -10,4 +10,8 @@ class DurationTest < Test::Unit::TestCase
assert_equal '7 days', 1.week.inspect
assert_equal '14 days', 1.fortnight.inspect
end
-end \ No newline at end of file
+
+ def test_minus_with_duration_does_not_break_subtraction_of_date_from_date
+ assert_nothing_raised { Date.today - Date.today }
+ end
+end