App-YG
view release on metacpan or search on metacpan
t/parser/apache-combined/01_parse.t view on Meta::CPAN
'30/Sep/2012:12:34:56 +0900',
'GET /foo HTTP/1.0',
'200',
'123',
'http://example.com/',
'Mozilla/5.0',
],
);
can_parse(
$parser_class,
'example.com - - [06/Aug/2012:12:34:56 +0900] "POST /bar HTTP/1.1" 404 4567 "http://example.com/index.html" "Mozilla/5.0 (compatible; Linux;)"',
[
'example.com',
'-',
'-',
'06/Aug/2012:12:34:56 +0900',
'POST /bar HTTP/1.1',
'404',
'4567',
'http://example.com/index.html',
'Mozilla/5.0 (compatible; Linux;)',
],
);
note '----- NG -----';
parse_fail(
$parser_class,
'this is bad log!'
t/parser/apache-common/01_parse.t view on Meta::CPAN
'-',
'-',
'30/Sep/2012:12:34:56 +0900',
'GET /foo HTTP/1.0',
'200',
'123',
],
);
can_parse(
$parser_class,
'example.com - - [06/Aug/2012:12:34:56 +0900] "POST /bar HTTP/1.1" 404 4567',
[
'example.com',
'-',
'-',
'06/Aug/2012:12:34:56 +0900',
'POST /bar HTTP/1.1',
'404',
'4567',
],
);
note '----- NG -----';
parse_fail(
$parser_class,
'this is bad log!'
);
parse_fail(
t/parser/nginx-main/01_parse.t view on Meta::CPAN
'GET /foo HTTP/1.0',
'200',
'123',
'http://example.com/',
'Mozilla/5.0',
'127.0.0.1',
],
);
can_parse(
$parser_class,
'example.com - - [06/Aug/2012:12:34:56 +0900] "POST /bar HTTP/1.1" 404 4567 "http://example.com/index.html" "Mozilla/5.0 (compatible; Linux;)" "proxy.example.com"',
[
'example.com',
'-',
'-',
'06/Aug/2012:12:34:56 +0900',
'POST /bar HTTP/1.1',
'404',
'4567',
'http://example.com/index.html',
'Mozilla/5.0 (compatible; Linux;)',
'proxy.example.com',
],
);
note '----- NG -----';
parse_fail(
$parser_class,
( run in 0.809 second using v1.01-cache-2.11-cpan-39bf76dae61 )