App-Wallflower
view release on metacpan or search on metacpan
t/30-links.t view on Meta::CPAN
Path::Tiny->new( t => 'file-01.html' )
],
'/style.css',
'/#content',
'/',
'/',
'/news.html',
'/credits.html',
'/contact.html',
'http://www.cpan.org/',
'/img/lorem.png',
],
[ '/foo/bar.css',
[ 200,
[ 'Content-Type' => 'text/css' ],
Path::Tiny->new( t => 'file-01.css' )
],
'/foo/foo.css', '/foo/bar.css', '/img.png', '/foo/img_qq.png', '/img_q.png', 'http://example.com/ex.png',
],
);
plan tests => scalar @tests;
for my $t (@tests) {
my ( $url, $response, @expected ) = @$t;
is_deeply( [ links_from( $response, $url ) ],
\@expected, "links for $response->[2]" );
}
t/file-01.css view on Meta::CPAN
@import "foo.css";
@import "bar.css";
h1 {
background: url(/img.png);
}
h2 {
background: url("img_qq.png");
}
h3 {
background: url('../img_q.png');
}
h4 {
background: url(http://example.com/ex.png);
}
t/file-01.html view on Meta::CPAN
<p>My <a href="file:///etc/passwd">local passwd</a> file.</p>
<p>
sapiente lorem quasi consequuntur anim illum odio adipisicing repudiandae
dolore repellendus maiores tempora eius ad voluptas placeat natus facilis
consequatur exercitation consequat iusto reiciendis molestiae fugiat
nostrud consectetur earum totam a eum esse voluptate commodo magna
repellat ea nesciunt vero officiis odit minus
velit
</p>
<p><img src="/img/lorem.png" /></p>
</body>
</html>
( run in 1.404 second using v1.01-cache-2.11-cpan-df04353d9ac )