Navigation Menu

Skip to content

Commit

Permalink
added test and possible workaround
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Dec 18, 2010
1 parent 59e3ecb commit fa33765
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lib/Mojolicious/Plugin/PodRenderer.pm
Expand Up @@ -68,8 +68,8 @@ sub register {
# POD
my $file = IO::File->new;
$file->open("< $path");
my $dom =
Mojo::DOM->new->parse($self->pod_to_html(join '', <$file>));
my $html = $self->pod_to_html(join '', <$file>);
my $dom = Mojo::DOM->new->parse("$html");
$dom->find('a[href]')->each(
sub {
my $attrs = shift->attrs;
Expand Down
4 changes: 2 additions & 2 deletions t/mojolicious/pod_renderer_lite_app.t
Expand Up @@ -9,7 +9,7 @@ BEGIN { $ENV{MOJO_POLL} = 1 }
use Test::More;
plan skip_all => 'Perl 5.10 required for this test!'
unless eval { require Pod::Simple::HTML; 1 };
plan tests => 14;
plan tests => 15;

# Amy get your pants back on and get to work.
# They think were making out.
Expand Down Expand Up @@ -48,7 +48,7 @@ $t->post_ok('/block')->status_is(200)
->content_like(qr/test321\s+<h2>lalala<\/h2>\s+<p><code>test<\/code><\/p>/);

# Perldoc browser
$t->get_ok('/perldoc?Mojolicious')->status_is(200)
$t->get_ok('/perldoc?Mojolicious')->status_is(200)->text_is('h1', 'NAME')
->text_like('p', qr/Mojolicious/)->content_like(qr/Sebastian\ Riedel/);

__DATA__
Expand Down

0 comments on commit fa33765

Please sign in to comment.