diff options
Diffstat (limited to 'test/test_time.rb')
-rw-r--r-- | test/test_time.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/test_time.rb b/test/test_time.rb index ca20788aac..d56daeb626 100644 --- a/test/test_time.rb +++ b/test/test_time.rb @@ -62,6 +62,13 @@ class TestTimeExtension < Test::Unit::TestCase # :nodoc: assert_equal(true, t.utc?) end + if defined?(Ractor) + def test_rfc2822_ractor + actual = Ractor.new { Time.rfc2822("Fri, 21 Nov 1997 09:55:06 -0600") }.take + assert_equal(Time.utc(1997, 11, 21, 9, 55, 6) + 6 * 3600, actual) + end + end + def test_encode_rfc2822 t = Time.utc(1) assert_equal("Mon, 01 Jan 0001 00:00:00 -0000", t.rfc2822) |