Skip to content

Commit

Permalink
more layout tests
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jan 31, 2016
1 parent d5000f4 commit fad35ff
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Changes
@@ -1,5 +1,5 @@

6.43 2016-01-30
6.43 2016-01-31
- Removed client_close and server_close methods from Mojo::Transaction.
- Added closed method to Mojo::Transaction.
- Added parse_message method to Mojo::Transaction::WebSocket.
Expand Down
11 changes: 9 additions & 2 deletions t/mojolicious/layouted_lite_app.t
Expand Up @@ -261,7 +261,7 @@ $t->get_ok('/withblocklayout')->status_is(200)
$t->get_ok('/content_for')->status_is(200)
->header_is(Server => 'Mojolicious (Perl)')
->content_is(
"DefaultThis\n\nseems\nto\nHello world!\n\nwork!\nShared content!\n\n");
"Content!This\n\nseems\nto\nHello world!\n\nwork!\n\nShared content!\n\n");
$t->get_ok('/content_with')->status_is(200)
->header_is(Server => 'Mojolicious (Perl)')
->content_is("Default\n\nSomething <b>else</b>!\n\n\n<br>Hello world!\n\n");
Expand Down Expand Up @@ -441,7 +441,11 @@ Two: <%= $two %>
<% end %>
with_block <%= $block->('one', 'two') %>
@@ layouts/content_for.html.ep
Content<%= title %><%= content_for 'more' %><%= content %>
@@ content_for.html.ep
% layout 'content_for';
This
<% content_for message => begin =%>Hello<% end %>
seems
Expand All @@ -450,9 +454,12 @@ seems
% end
to
<%= content_for 'message' %>
work!
%= include 'content_for_partial'
%= content_for 'stuff'
@@ content_for_partial.html.ep
<% content_for more => begin %>!<% end %>work!
@@ content_with.html.ep
<% content first => begin %>Something<% end %>
<% content_for first => begin %> <b>else<% end %>
Expand Down

0 comments on commit fad35ff

Please sign in to comment.