Skip to content

Commit

Permalink
Test case for #144
Browse files Browse the repository at this point in the history
  • Loading branch information
ultraq committed Nov 28, 2016
1 parent 21d3805 commit 5c47fcd
Showing 1 changed file with 58 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@

# Replicate a bug found with deep hierarchies, as per
# /~https://github.com/ultraq/thymeleaf-layout-dialect/issues/144

% TEMPLATE_MODE HTML

%INPUT
<html layout:decorate="~{header}">
<head>
<title>Some Title</title>
<script>alert('hello');</script>
</head>
<body>
<div layout:fragment="content">
<p>Some Content</p>
</div>
</body>
</html>


%INPUT[header]
<html layout:decorate="~{master}">
<head></head>
<body>
<div layout:fragment="page">
<a th:href="@{/home}">Home</a>
<div layout:fragment="content"></div>
</div>
</body>
</html>


%INPUT[master]
<html>
<head>
<title>default title</title>
</head>
<body>
<div layout:fragment="page"></div>
</body>
</html>


%OUTPUT
<html>
<head>
<title>Some title</title>
<script>alert('hello);</script>
</head>
<body>
<div>
<a href="/home">Home</a>
<div>
<p>Some Content</p>
</div>
</div>
</body>
</html>

0 comments on commit 5c47fcd

Please sign in to comment.