2022-11-25 19:39:51 -05:00
|
|
|
{% extends 'layout.twig' %}
|
|
|
|
|
2024-06-03 09:42:50 -04:00
|
|
|
{% block title %}Test: {{ test.title }}{% endblock %}
|
2022-11-25 19:39:51 -05:00
|
|
|
|
|
|
|
{% block content %}
|
|
|
|
<div class="row">
|
|
|
|
<div class="twelve columns">
|
2024-04-06 12:08:23 -04:00
|
|
|
<h1>{{ test.title }}</h1>
|
2022-11-25 19:39:51 -05:00
|
|
|
<p>{{ test.description }}</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<hr>
|
|
|
|
|
2024-06-03 10:36:18 -04:00
|
|
|
<div class="row">
|
|
|
|
<div class="twelve columns">
|
|
|
|
<form id="result-form" class="u-full-width" action="{{ url_for('result.add') }}" method="POST">
|
|
|
|
<div class="row">
|
|
|
|
<div class="four columns">
|
2024-06-03 10:52:00 -04:00
|
|
|
<select class="u-full-width" name="result_benchmark">
|
2024-06-03 10:51:20 -04:00
|
|
|
{% for b in test.benchmarks %}
|
2024-06-03 10:36:18 -04:00
|
|
|
<option value="{{ b.id }}">{{ b.name }}</option>
|
|
|
|
{% endfor %}
|
|
|
|
</select>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="two columns">
|
|
|
|
<input type="number" step="0.01" name="result_avg" placeholder="0.0">
|
|
|
|
</div>
|
|
|
|
<div class="two columns">
|
|
|
|
<input type="number" step="0.01" name="result_min" placeholder="0.0">
|
|
|
|
</div>
|
|
|
|
<div class="two columns">
|
|
|
|
<input type="number" step="0.01" name="result_max" placeholder="0.0">
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="two columns">
|
2024-06-03 10:52:29 -04:00
|
|
|
<button class="button-primary u-full-width" type="submit" name="button">Submit</button>
|
2024-06-03 10:36:18 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<input type="hidden" name="result_test" value="{{ test.id }}">
|
|
|
|
<input type="hidden" name="result_component" value="{{ test.component().id }}">
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<hr>
|
|
|
|
|
2022-11-25 19:39:51 -05:00
|
|
|
<div class="row">
|
|
|
|
<div class="twelve columns">
|
2024-06-03 11:28:24 -04:00
|
|
|
<h3>Benchmark results:</h3>
|
2022-11-25 19:39:51 -05:00
|
|
|
|
2024-06-03 11:28:24 -04:00
|
|
|
<table class="u-full-width">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Benchmark</th>
|
|
|
|
<th>Scoring</th>
|
|
|
|
<th># Results</th>
|
|
|
|
<th>Avg.</th>
|
|
|
|
<th>Min.</th>
|
|
|
|
<th>Max.</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for r in test.benchmarkResults() %}
|
2022-11-25 19:39:51 -05:00
|
|
|
<tr>
|
2024-06-03 11:28:24 -04:00
|
|
|
<td>{{ r.name }}</td>
|
|
|
|
<td>{{ r.scoring | capitalize }}</td>
|
|
|
|
<td>{{ r.count }}</td>
|
|
|
|
<td>{{ r.average }}</td>
|
|
|
|
<td>{{ r.minimum ? r.minimum : 'N/a' }}</td>
|
|
|
|
<td>{{ r.maximum ? r.maximum : 'N/a' }}</td>
|
2022-11-25 19:39:51 -05:00
|
|
|
</tr>
|
2024-06-03 11:28:24 -04:00
|
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2022-11-25 19:39:51 -05:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{% endblock %}
|