Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #3764 from arunagw/test_sunday_monday

Tests added for monday and sunday
  • Loading branch information...
commit 9030cdadff8c7c859ba404c1d67b55f0441cdbf5 2 parents ab854db + cd6c567
@vijaydev vijaydev authored
Showing with 8 additions and 0 deletions.
  1. +8 −0 activesupport/test/core_ext/date_ext_test.rb
View
8 activesupport/test/core_ext/date_ext_test.rb
@@ -57,6 +57,14 @@ def test_beginning_of_week
assert_equal Date.new(2005,11,28), Date.new(2005,12,04).beginning_of_week #sunday
end
+ def test_monday
+ assert_equal Date.new(2005,11,28), Date.new(2005,11,28).monday
+ end
+
+ def test_sunday
+ assert_equal Date.new(2008,3,2), Date.new(2008,3,02).sunday
+ end
+
def test_beginning_of_week_in_calendar_reform
assert_equal Date.new(1582,10,1), Date.new(1582,10,15).beginning_of_week #friday
end
Please sign in to comment.
Something went wrong with that request. Please try again.