knock more errors from test files
This commit is contained in:
parent
563e8e8f54
commit
071b7b9731
|
@ -24,7 +24,7 @@ func TestJSONParserCompile(t *testing.T) {
|
||||||
testDir := getPluginDir()
|
testDir := getPluginDir()
|
||||||
var acc testutil.Accumulator
|
var acc testutil.Accumulator
|
||||||
r := Reader{
|
r := Reader{
|
||||||
Filepaths: []string{testDir + "/reader/testfiles/**.log"},
|
Filepaths: []string{testDir + "/reader/testfiles/json_a.log"},
|
||||||
DataFormat: "json",
|
DataFormat: "json",
|
||||||
Tags: []string{"parent_ignored_child"},
|
Tags: []string{"parent_ignored_child"},
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,7 +12,6 @@ func TestGrokParse(t *testing.T) {
|
||||||
Measurement: "t_met",
|
Measurement: "t_met",
|
||||||
Patterns: []string{"%{COMMON_LOG_FORMAT}"},
|
Patterns: []string{"%{COMMON_LOG_FORMAT}"},
|
||||||
}
|
}
|
||||||
//var acc testutil.Accumulator
|
|
||||||
parser.Compile()
|
parser.Compile()
|
||||||
metrics, err := parser.Parse([]byte(`127.0.0.1 user-identifier frank [10/Oct/2000:13:55:36 -0700] "GET /apache_pb.gif HTTP/1.0" 200 2326`))
|
metrics, err := parser.Parse([]byte(`127.0.0.1 user-identifier frank [10/Oct/2000:13:55:36 -0700] "GET /apache_pb.gif HTTP/1.0" 200 2326`))
|
||||||
log.Printf("metric_tags: %v, metric_fields: %v", metrics[0].Tags(), metrics[0].Fields())
|
log.Printf("metric_tags: %v, metric_fields: %v", metrics[0].Tags(), metrics[0].Fields())
|
||||||
|
|
Loading…
Reference in New Issue