Kouhei Sutou
null+****@clear*****
Thu Sep 28 09:06:36 JST 2017
Kouhei Sutou 2017-09-28 09:06:36 +0900 (Thu, 28 Sep 2017) New Revision: 42c954a1360ebd95dfba05f5bb056d2a26898383 https://github.com/groonga/groonga-log/commit/42c954a1360ebd95dfba05f5bb056d2a26898383 Message: Add a test for invalid octal number case such as "09" Modified files: test/test-parser.rb Modified: test/test-parser.rb (+3 -3) =================================================================== --- test/test-parser.rb 2017-09-27 19:07:05 +0900 (f7db9d0) +++ test/test-parser.rb 2017-09-28 09:06:36 +0900 (766151b) @@ -20,12 +20,12 @@ require "helper" class ParserTest < Test::Unit::TestCase def test_extract_field raw_statistic = { - :timestamp => Time.local(2017, 7, 19, 14, 41, 5, 663978), + :timestamp => Time.local(2017, 7, 19, 14, 9, 5, 663978), :year => 2017, :month => 7, :day => 19, :hour => 14, - :minute => 41, + :minute => 9, :second => 5, :micro_second => 663978, :log_level => :notice, @@ -33,7 +33,7 @@ class ParserTest < Test::Unit::TestCase :message => "spec:2:update:Object:32(type):8", } statistics = parse(<<-LOG) -2017-07-19 14:41:05.663978|n|18c61700|spec:2:update:Object:32(type):8 +2017-07-19 14:09:05.663978|n|18c61700|spec:2:update:Object:32(type):8 LOG assert_equal([raw_statistic], statistics.collect(&:to_h)) -------------- next part -------------- HTML����������������������������... URL: https://lists.osdn.me/mailman/archives/groonga-commit/attachments/20170928/87702d7f/attachment.htm