From b5c619c2af130ab7f491c9fd752fe791854a620a Mon Sep 17 00:00:00 2001 From: TAGOMORI Satoshi Date: Mon, 4 Jul 2016 12:10:12 +0900 Subject: [PATCH] Just a single value was invalid as JSON object in traditional way * This test code fails on Travis OSX environment * It's a bit curious and cannot be reproduced in my laptop, but not important to spend time for it --- test/test_event_time.rb | 3 --- 1 file changed, 3 deletions(-) diff --git a/test/test_event_time.rb b/test/test_event_time.rb index aff0f7b5de..3f7a3d6b16 100644 --- a/test/test_event_time.rb +++ b/test/test_event_time.rb @@ -45,21 +45,18 @@ class EventTimeTest < Test::Unit::TestCase test 'JSON.dump' do time = Fluent::EventTime.new(100) - assert_equal('100', JSON.dump(time)) assert_equal('{"time":100}', JSON.dump({'time' => time})) assert_equal('["tag",100,{"key":"value"}]', JSON.dump(["tag", time, {"key" => "value"}])) end test 'Oj.dump' do time = Fluent::EventTime.new(100) - assert_equal('100', Oj.dump(time, mode: :compat)) assert_equal('{"time":100}', Oj.dump({'time' => time}, mode: :compat)) assert_equal('["tag",100,{"key":"value"}]', Oj.dump(["tag", time, {"key" => "value"}], mode: :compat)) end test 'Yajl.dump' do time = Fluent::EventTime.new(100) - assert_equal('100', Yajl.dump(time)) assert_equal('{"time":100}', Yajl.dump({'time' => time})) assert_equal('["tag",100,{"key":"value"}]', Yajl.dump(["tag", time, {"key" => "value"}])) end