review/templates/pieces/comment.html @ 9030dc9517cf
web: add basic tests
This patch adds a new test module `test_web` to automate testing of web
requests. For now the tests are rather simple and only check for
expected status codes.
To set up the flask app within the tests, it has to be configured
properly. This is the reason why the app configuration part in `web.py`
has been moved into an own function - now it may also be used by the
test module.
author |
Oben Sonne <obensonne@googlemail.com> |
date |
Mon, 02 Jul 2012 22:32:48 +0200 |
parents |
5dec221dd171 |
children |
0dc141617716 |
{% if comment.style == 'markdown' %}
{% set rendered = utils['markdown'](comment.message) %}
{% endif %}
<div class="comment group" id="comment-{{ comment.identifier }}">
<a href="#comment-{{ comment.identifier }}" rel="comments" class="expand" id="comment-expand-{{ comment.identifier }}">→</a>
<script type="text/javascript">
$(function() {
$("#comment-expand-{{ comment.identifier }}").colorbox({inline: true, href: "#comment-{{ comment.identifier }}-colorboxed"});
});
</script>
<div class="avatar">
<img src="{{ utils['item_gravatar'](comment, 30) }}" />
</div>
<div>
<div class="author">
<a href="mailto:{{ utils['email'](comment.author) }}">{{ utils['templatefilters'].person(comment.author) }}</a>
said:
</div>
{% if comment.style == 'markdown' %}
<div class="message markdown">{{ rendered|safe }}</div>
{% else %}
<div class="message plain">{{ comment.message }}</div>
{% endif %}
</div>
<div id="comment-{{ comment.identifier }}-colorboxed" class="colorboxed">
<div class="avatar">
<img src="{{ utils['item_gravatar'](comment, 30) }}" />
</div>
<div>
<div class="author">
<a href="mailto:{{ utils['email'](comment.author) }}">{{ utils['templatefilters'].person(comment.author) }}</a>
said:
</div>
<div class="context">
{% if comment.ufilename %}
<div class="context-head">on {{ comment.ufilename }}</div>
{% else %}
<div class="context-head">on changeset {{ rev.rev() }}:{{ utils['node_short'](rev.node()) }}</div>
{% endif %}
</div>
<div class="message">{{ comment.message }}</div>
</div>
</div>
{% if not read_only %}
{% include "pieces/forms/comment-change.html" %}
{% endif %}
</div>