From a8aaef676217f53f2812cd56f71a6b00c5d22162 Mon Sep 17 00:00:00 2001 From: Willem van Bergen Date: Thu, 15 Sep 2011 09:50:39 -0400 Subject: Fixed tests so that they will also run properly in other timezones. --- activesupport/test/message_verifier_test.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'activesupport/test/message_verifier_test.rb') diff --git a/activesupport/test/message_verifier_test.rb b/activesupport/test/message_verifier_test.rb index 83f34ebc33..224e38a52a 100644 --- a/activesupport/test/message_verifier_test.rb +++ b/activesupport/test/message_verifier_test.rb @@ -37,8 +37,8 @@ class MessageVerifierTest < Test::Unit::TestCase @verifier.serializer = lambda { |value| ActiveSupport::JSON.encode(value) } @verifier.deserializer = lambda { |value| ActiveSupport::JSON.decode(value) } - message = @verifier.generate({ :foo => 123, 'bar' => Time.local(2010) }) - assert_equal @verifier.verify(message), { "foo" => 123, "bar" => "2010-01-01T00:00:00-05:00" } + message = @verifier.generate({ :foo => 123, 'bar' => Time.utc(2010) }) + assert_equal @verifier.verify(message), { "foo" => 123, "bar" => "2010-01-01T00:00:00Z" } end def assert_not_verified(message) -- cgit v1.2.3