提交 4e05e9e7 编写于 作者: Y Yves Senn

Merge pull request #17876 from claudiob/fix-tests-on-4-0-stable

Fix tests on 4-0-stable
......@@ -317,11 +317,11 @@ def test_string_to_time_utc_offset
end
def test_partial_string_to_time
with_env_tz "Europe/Moscow" do
with_env_tz "Europe/Moscow" do # use timezone which does not observe DST.
now = Time.now
assert_equal Time.local(now.year, now.month, now.day, 23, 50), "23:50".to_time
assert_equal Time.utc(now.year, now.month, now.day, 23, 50), "23:50".to_time(:utc)
assert_equal Time.local(now.year, now.month, now.day, 18, 50), "13:50 -0100".to_time
assert_equal Time.local(now.year, now.month, now.day, 17, 50), "13:50 -0100".to_time
assert_equal Time.utc(now.year, now.month, now.day, 23, 50), "22:50 -0100".to_time(:utc)
end
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册