@@ -29,20 +29,22 @@ import (
2929
3030func TestMergeConfigs (t * testing.T ) {
3131 a := & Config {
32- Version : 2 ,
33- Root : "old_root" ,
34- RequiredPlugins : []string {"old_plugin" },
35- DisabledPlugins : []string {"old_plugin" },
36- State : "old_state" ,
37- OOMScore : 1 ,
38- Timeouts : map [string ]string {"a" : "1" },
32+ Version : 2 ,
33+ Root : "old_root" ,
34+ RequiredPlugins : []string {"old_plugin" },
35+ DisabledPlugins : []string {"old_plugin" },
36+ State : "old_state" ,
37+ OOMScore : 1 ,
38+ Timeouts : map [string ]string {"a" : "1" },
39+ StreamProcessors : map [string ]StreamProcessor {"1" : {Path : "2" , Returns : "4" }, "2" : {Path : "5" }},
3940 }
4041
4142 b := & Config {
42- Root : "new_root" ,
43- RequiredPlugins : []string {"new_plugin1" , "new_plugin2" },
44- OOMScore : 2 ,
45- Timeouts : map [string ]string {"b" : "2" },
43+ Root : "new_root" ,
44+ RequiredPlugins : []string {"new_plugin1" , "new_plugin2" },
45+ OOMScore : 2 ,
46+ Timeouts : map [string ]string {"b" : "2" },
47+ StreamProcessors : map [string ]StreamProcessor {"1" : {Path : "3" }},
4648 }
4749
4850 err := mergeConfig (a , b )
@@ -55,6 +57,7 @@ func TestMergeConfigs(t *testing.T) {
5557 assert .DeepEqual (t , a .RequiredPlugins , []string {"old_plugin" , "new_plugin1" , "new_plugin2" })
5658 assert .DeepEqual (t , a .DisabledPlugins , []string {"old_plugin" })
5759 assert .DeepEqual (t , a .Timeouts , map [string ]string {"a" : "1" , "b" : "2" })
60+ assert .DeepEqual (t , a .StreamProcessors , map [string ]StreamProcessor {"1" : {Path : "3" }, "2" : {Path : "5" }})
5861}
5962
6063func TestResolveImports (t * testing.T ) {
0 commit comments