From f449da53ac69495e736c7f1ce0f1bc6ebe356081 Mon Sep 17 00:00:00 2001 From: Nate Mueller Date: Thu, 2 Jun 2011 20:43:23 -0700 Subject: Make String.to_time respect timezones --- activesupport/test/core_ext/string_ext_test.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'activesupport/test/core_ext/string_ext_test.rb') diff --git a/activesupport/test/core_ext/string_ext_test.rb b/activesupport/test/core_ext/string_ext_test.rb index 32675c884a..0fd0cb8ac7 100644 --- a/activesupport/test/core_ext/string_ext_test.rb +++ b/activesupport/test/core_ext/string_ext_test.rb @@ -158,6 +158,7 @@ class StringInflectionsTest < Test::Unit::TestCase assert_equal Time.local(2005, 2, 27, 23, 50, 19, 275038), "2005-02-27T23:50:19.275038".to_time(:local) assert_equal DateTime.civil(2039, 2, 27, 23, 50), "2039-02-27 23:50".to_time assert_equal Time.local_time(2039, 2, 27, 23, 50), "2039-02-27 23:50".to_time(:local) + assert_equal Time.utc(2039, 2, 27, 23, 50), "2039-02-27 22:50 -0100".to_time assert_nil "".to_time end -- cgit v1.2.3