root/trunk/plagger/t/plugins/Filter-TruePermalink/redirect.t

Revision 1689 (checked in by miyagawa, 14 years ago)

Filter::TruePermalink?: don't die if it detects infinite loop on HTTP redirects.

Line 
1 use t::TestPlagger;
2
3 test_requires_network;
4 plan 'no_plan';
5 run_eval_expected;
6
7 __END__
8
9 === redirect
10 --- input config
11 plugins:
12   - module: CustomFeed::Debug
13     config:
14       title: foo
15       link: http://localhost/
16       entry:
17         - title: bar
18           link: http://gimite.ddo.jp/rotd/click.rb?hid=tbcl&id=tag:hatena.ne.jp,2005-2006:bookmark-miyagawa-2605184&url=http://subtech.g.hatena.ne.jp/miyagawa/20060823/1156317748
19         - title: baz
20           link: http://xrl.us/q54v
21         - title: x
22           link: http://tech.groups.yahoo.com/group/ydn-delicious/message/436
23   - module: Filter::TruePermalink
24 --- expected
25 unlike $context->update->feeds->[0]->entries->[0]->permalink, qr/click\.rb/;
26 like $context->update->feeds->[0]->entries->[0]->permalink, qr/subtech/;
27 unlike $context->update->feeds->[0]->entries->[0]->permalink, qr/xrl\.us/;
28 like $context->update->feeds->[0]->entries->[0]->permalink, qr/subtech/;
Note: See TracBrowser for help on using the browser.