diff options
| author | Paul Bütow <pbuetow@mimecast.com> | 2020-01-20 18:41:05 +0000 |
|---|---|---|
| committer | Paul Bütow <pbuetow@mimecast.com> | 2020-01-21 14:35:23 +0000 |
| commit | c128865c4c7411c29a59fca9a3a2f95537686d7b (patch) | |
| tree | 193bccc70d942c8b70cc93fae2670263701e43aa /mapr/logformat/default_test.go | |
| parent | 3755a9911ecb05886577095f2b8cc8b9e4066a3a (diff) | |
Move commands to cmd/ and move internal dependencies to internal/
Diffstat (limited to 'mapr/logformat/default_test.go')
| -rw-r--r-- | mapr/logformat/default_test.go | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/mapr/logformat/default_test.go b/mapr/logformat/default_test.go deleted file mode 100644 index a3c47fb..0000000 --- a/mapr/logformat/default_test.go +++ /dev/null @@ -1,35 +0,0 @@ -package logformat - -import ( - "testing" -) - -func TestDefaultLogFormat(t *testing.T) { - parser, err := NewParser("default") - if err != nil { - t.Errorf("Unable to create parser: %s", err.Error()) - } - - fields, err := parser.MakeFields("foo=bar|baz=bay") - - if err != nil { - t.Errorf("Unable to parse: %s", err.Error()) - } - - if bar, ok := fields["foo"]; !ok { - t.Errorf("Expected field 'foo', but no such field there\n") - } else if bar != "bar" { - t.Errorf("Expected 'bar' stored in field 'foo', but got '%s'\n", bar) - } - - if bay, ok := fields["baz"]; !ok { - t.Errorf("Expected field 'baz', but no such field there\n") - } else if bay != "bay" { - t.Errorf("Expected 'bay' stored in field 'baz', but got '%s'\n", bay) - } - - fields, err = parser.MakeFields("foo=bar|bazbay") - if err == nil { - t.Errorf("Expected error but didn't: %s", err.Error()) - } -} |
