From 13d42dc3c9079d0fb7a38166295a56a3f046325e Mon Sep 17 00:00:00 2001 From: abetomo Date: Thu, 9 Mar 2023 09:39:23 +0900 Subject: [PATCH] Use driver for RegexpParser tests Signed-off-by: abetomo --- test/plugin/test_parser_regexp.rb | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/test/plugin/test_parser_regexp.rb b/test/plugin/test_parser_regexp.rb index 7fc5a98604..b5a5c5fb30 100644 --- a/test/plugin/test_parser_regexp.rb +++ b/test/plugin/test_parser_regexp.rb @@ -28,12 +28,7 @@ def create_driver(regexp, conf = {}, initialize_conf: false) if initialize_conf Fluent::Test::Driver::Parser.new(Fluent::Compat::TextParser::RegexpParser.new(regexp, conf)) else - # Fluent::Test::Driver::Parser.new(Fluent::Compat::TextParser::RegexpParser.new(regexp)).configure(conf) - instance = Fluent::Compat::TextParser::RegexpParser.new(regexp) - instance.configure(conf) - d = Struct.new(:instance).new - d.instance = instance - d + Fluent::Test::Driver::Parser.new(Fluent::Compat::TextParser::RegexpParser.new(regexp)).configure(conf) end end