test/plugin/test_output.rb in fluentd-1.8.1 vs test/plugin/test_output.rb in fluentd-1.9.0.rc1
- old
+ new
@@ -853,20 +853,20 @@
end
sub_test_case 'configure secondary' do
test "Warn if primary type is different from secondary type and either primary or secondary has custom_format" do
o = create_output(:buffered)
- mock(o.log).warn("secondary type should be same with primary one",
+ mock(o.log).warn("Use different plugin for secondary. Check the plugin works with primary like secondary_file",
{ primary: o.class.to_s, secondary: "Fluent::Plugin::TestOutput" })
o.configure(config_element('ROOT','',{},[config_element('secondary','',{'@type'=>'test', 'name' => "cool"})]))
assert_not_nil o.instance_variable_get(:@secondary)
end
test "don't warn if primary type is the same as secondary type" do
o = Fluent::Plugin::TestOutput.new
- mock(o.log).warn("secondary type should be same with primary one",
+ mock(o.log).warn("Use different plugin for secondary. Check the plugin works with primary like secondary_file",
{ primary: o.class.to_s, secondary: "Fluent::Plugin::TestOutput" }).never
o.configure(config_element('ROOT','',{'name' => "cool2"},
[config_element('secondary','',{'@type'=>'test', 'name' => "cool"}),
config_element('buffer','',{'@type'=>'memory'})]
@@ -874,10 +874,10 @@
assert_not_nil o.instance_variable_get(:@secondary)
end
test "don't warn if primary type is different from secondary type and both don't have custom_format" do
o = create_output(:standard)
- mock(o.log).warn("secondary type should be same with primary one",
+ mock(o.log).warn("Use different plugin for secondary. Check the plugin works with primary like secondary_file",
{ primary: o.class.to_s, secondary: "Fluent::Plugin::TestOutput" }).never
o.configure(config_element('ROOT','',{},[config_element('secondary','',{'@type'=>'test', 'name' => "cool"})]))
assert_not_nil o.instance_variable_get(:@secondary)
end