hack to make running input plugins

This commit is contained in:
Jordan Sissel 2012-09-03 23:37:43 -07:00
parent 215a40e401
commit 7e47e194ec

View file

@ -48,6 +48,16 @@ module LogStash
end
end # def sample
def input(&block)
require "logstash/config/file"
config = LogStash::Config::File.new(nil, @config_str)
agent = LogStash::Agent.new
it "looks good" do
inputs, filters, outputs = agent.instance_eval { parse_config(config) }
block.call(inputs)
end
end # def input
def agent(&block)
@agent_count ||= 0
require "logstash/agent"