1# The client writes a message to Sys::Syslog native method. 2# The syslogd writes it into a file and through a pipe. 3# The syslogd passes it via UDP to the loghost. 4# The server receives the message on its UDP socket. 5# Find the message in client, file, pipe, syslogd, server log. 6# Check that there are no bogous new lines in the client log and file. 7 8use strict; 9use warnings; 10 11our %args = ( 12 client => { 13 func => sub { 14 my $self = shift; 15 write_message($self, "foo"); 16 write_message($self, "bar\n"); 17 write_message($self, "foobar\n\n"); 18 write_message($self, ""); 19 write_message($self, "\n"); 20 write_message($self, "\n\n"); 21 write_log($self); 22 }, 23 loggrep => { 24 qr/^\s*$/ => 0, 25 qr/[^:] +$/ => 0, 26 qr/: $/ => 3, 27 }, 28 }, 29 file => { 30 loggrep => { 31 qr/^\s*$/ => 0, 32 qr/[^:] +$/ => 0, 33 qr/: $/ => 1, 34 }, 35 }, 36); 37 381; 39