Skip to content

Commit

Permalink
test generated ids
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jul 26, 2014
1 parent ae38e38 commit bc03be9
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions t/mojolicious/pod_renderer_lite_app.t
Expand Up @@ -31,16 +31,17 @@ my $t = Test::Mojo->new;

# Simple POD template
$t->get_ok('/')->status_is(200)
->content_like(qr|<h1.*>Test123</h1>\s+<p>It <code>works</code>!</p>|);
->content_like(qr!<h1 id="Test123">Test123</h1>!)
->content_like(qr|<p>It <code>works</code>!</p>|);

# POD helper
$t->post_ok('/')->status_is(200)->content_like(qr!test123<h1.*>A</h1>!)
->content_like(qr!<h1.*>B</h1>!)
$t->post_ok('/')->status_is(200)->content_like(qr!test123<h1 id="A">A</h1>!)
->content_like(qr!<h1 id="B">B</h1>!)
->content_like(qr!\s+<p><code>test</code></p>!)->content_like(qr/Gray/);

# POD filter
$t->post_ok('/block')->status_is(200)
->content_like(qr!test321<h2.*>lalala</h2>!)
->content_like(qr!test321<h2 id="lalala">lalala</h2>!)
->content_like(qr!<p><code>test</code></p>!)->content_like(qr/Gray/);

# Empty
Expand Down

0 comments on commit bc03be9

Please sign in to comment.