@@ -46,6 +46,7 @@ func (s *Rfc3164TestSuite) TestParser_Valid(c *C) {
46
46
"timestamp" : time .Date (now .Year (), time .October , 11 , 22 , 14 , 15 , 0 , time .UTC ),
47
47
"hostname" : "mymachine" ,
48
48
"tag" : "very.large.syslog.message.tag" ,
49
+ "pid" : "" ,
49
50
"content" : "'su root' failed for lonvick on /dev/pts/8" ,
50
51
"priority" : 34 ,
51
52
"facility" : 4 ,
@@ -78,6 +79,7 @@ func (s *Rfc3164TestSuite) TestParser_ValidNoTag(c *C) {
78
79
"timestamp" : time .Date (now .Year (), time .October , 11 , 22 , 14 , 15 , 0 , time .UTC ),
79
80
"hostname" : "mymachine" ,
80
81
"tag" : "" ,
82
+ "pid" : "" ,
81
83
"content" : "singleword" ,
82
84
"priority" : 34 ,
83
85
"facility" : 4 ,
@@ -112,6 +114,7 @@ func (s *Rfc3164TestSuite) TestParser_NoTimestamp(c *C) {
112
114
"timestamp" : now ,
113
115
"hostname" : "" ,
114
116
"tag" : "" ,
117
+ "pid" : "" ,
115
118
"content" : "INFO leaving (1) step postscripts" ,
116
119
"priority" : 14 ,
117
120
"facility" : 1 ,
@@ -164,6 +167,7 @@ func (s *Rfc3164TestSuite) TestParser_ValidRFC3339Timestamp(c *C) {
164
167
"timestamp" : time .Date (2018 , time .January , 12 , 22 , 14 , 15 , 0 , time .UTC ),
165
168
"hostname" : "mymachine" ,
166
169
"tag" : "app" ,
170
+ "pid" : "101" ,
167
171
"content" : "msg" ,
168
172
"priority" : 34 ,
169
173
"facility" : 4 ,
@@ -184,7 +188,8 @@ func (s *Rfc3164TestSuite) TestParsemessage_Valid(c *C) {
184
188
buff := []byte ("sometag[123]: " + content )
185
189
hdr := rfc3164message {
186
190
tag : "sometag" ,
187
- content : content ,
191
+ pid : "123" ,
192
+ content : content
188
193
}
189
194
190
195
s .assertRfc3164message (c , hdr , buff , len (buff ), syslogparser .ErrEOL )
0 commit comments