Add support for viewing jobset evaluations
This commit is contained in:
@ -7,23 +7,10 @@
|
||||
[% ELSIF project %] for Project <tt>[% project.name %]</tt>[% END %]</h1>
|
||||
|
||||
<p>Showing builds [% (page - 1) * resultsPerPage + 1 %] - [% (page - 1) * resultsPerPage + builds.size %]
|
||||
out of [% totalBuilds %] in order of descending timestamp.</p>
|
||||
out of [% total %] in order of descending timestamp.</p>
|
||||
|
||||
[% BLOCK renderNav %]
|
||||
<p>
|
||||
[<a href="[% "$baseUri?page=1" %]">First</a>]
|
||||
[% IF page > 1 %]
|
||||
[<a href="[% "$baseUri?page="; (page - 1) %]">Prev</a>]
|
||||
[% END %]
|
||||
[% IF page * resultsPerPage < totalBuilds %]
|
||||
[<a href="[% "$baseUri?page="; (page + 1) %]">Next</a>]
|
||||
[% END %]
|
||||
[<a href="[% "$baseUri?page="; (totalBuilds - 1) div resultsPerPage + 1 %]">Last</a>]
|
||||
</p>
|
||||
[% END %]
|
||||
|
||||
[% INCLUDE renderNav %]
|
||||
[% INCLUDE renderPager %]
|
||||
[% INCLUDE renderBuildList hideProjectName=project hideJobsetName=jobset hideJobName=job %]
|
||||
[% INCLUDE renderNav %]
|
||||
[% INCLUDE renderPager %]
|
||||
|
||||
[% END %]
|
||||
|
@ -62,8 +62,8 @@
|
||||
[% END %]
|
||||
|
||||
|
||||
[%- BLOCK renderBuildList -%]
|
||||
<table class="buildList tablesorter[% IF !showSchedulingInfo %] clean[% END %]">
|
||||
[%- BLOCK renderBuildListHeader -%]
|
||||
<table class="buildList [% IF !unsortable %]tablesorter[% END %] [% IF !showSchedulingInfo %] clean[% END %]">
|
||||
<thead>
|
||||
<tr>
|
||||
[%- IF !hideResultInfo -%]
|
||||
@ -89,6 +89,9 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
[%- END -%]
|
||||
|
||||
[%- BLOCK renderBuildListBody -%]
|
||||
[%- odd = 0 -%]
|
||||
[%- FOREACH build IN builds -%]
|
||||
<tr class="clickable
|
||||
@ -130,10 +133,20 @@
|
||||
[%- END -%]
|
||||
</tr>
|
||||
[%- END -%]
|
||||
[%- END -%]
|
||||
|
||||
[%- BLOCK renderBuildListFooter -%]
|
||||
</tbody>
|
||||
</table>
|
||||
[%- END -%]
|
||||
|
||||
[%- BLOCK renderBuildList -%]
|
||||
[%- INCLUDE renderBuildListHeader -%]
|
||||
[%- INCLUDE renderBuildListBody -%]
|
||||
[%- INCLUDE renderBuildListFooter -%]
|
||||
[%- END -%]
|
||||
|
||||
|
||||
[%- BLOCK renderLink -%]<a href="[% uri %]">[% title %]</a>[%- END -%]
|
||||
|
||||
[%- BLOCK showBuildStats -%]
|
||||
@ -377,8 +390,18 @@
|
||||
</table>
|
||||
[% END %]
|
||||
|
||||
[% BLOCK buildsGraph %]
|
||||
|
||||
|
||||
|
||||
[% BLOCK renderPager %]
|
||||
<p>
|
||||
[<a href="[% "$baseUri?page=1" %]">First</a>]
|
||||
[% IF page > 1 %]
|
||||
[<a href="[% "$baseUri?page="; (page - 1) %]">Prev</a>]
|
||||
[% END %]
|
||||
[% IF page * resultsPerPage < total %]
|
||||
[<a href="[% "$baseUri?page="; (page + 1) %]">Next</a>]
|
||||
[% END %]
|
||||
[<a href="[% "$baseUri?page="; (total - 1) div resultsPerPage + 1 %]">Last</a>]
|
||||
</p>
|
||||
[% END %]
|
||||
|
||||
|
||||
|
41
src/root/jobset-eval.tt
Normal file
41
src/root/jobset-eval.tt
Normal file
@ -0,0 +1,41 @@
|
||||
[% WRAPPER layout.tt title="Bla" %]
|
||||
[% PROCESS common.tt %]
|
||||
|
||||
<h1>Jobset <tt>[% project.name %]:[% jobset.name %]</tt> Evaluation [% eval.id %]</h1>
|
||||
|
||||
<!-- <p>Info on evaluation [% eval.id %]...<p> -->
|
||||
|
||||
[%- BLOCK renderSome -%]
|
||||
[% size = builds.size; max = full ? size : 30; %]
|
||||
[% INCLUDE renderBuildListBody builds=builds.slice(0, (size > max ? max : size) - 1)
|
||||
hideProjectName=1 hideJobsetName=1 %]
|
||||
[% IF size > max %]
|
||||
<tr><td class="centered" colspan="0"><a href="[% c.uri_for(c.controller('JobsetEval').action_for('view'), [eval.id], full => 1) %]"><em>([% size - max %] more builds omitted)</em></a></td></tr>
|
||||
[% END %]
|
||||
[% END %]
|
||||
|
||||
[% INCLUDE renderBuildListHeader unsortable=1 %]
|
||||
|
||||
[% IF nowFail.size > 0 %]
|
||||
<tr><th class="subheader" colspan="0">Builds that now <strong>fail</strong></th></tr>
|
||||
[% INCLUDE renderSome builds=nowFail %]
|
||||
[% END %]
|
||||
|
||||
[% IF nowSucceed.size > 0 %]
|
||||
<tr><th class="subheader" colspan="0">Builds that now <strong>succeed</strong></th></tr>
|
||||
[% INCLUDE renderSome builds=nowSucceed %]
|
||||
[% END %]
|
||||
|
||||
[% IF stillFail.size > 0 %]
|
||||
<tr><th class="subheader" colspan="0">Builds that still <strong>fail</strong></th></tr>
|
||||
[% INCLUDE renderSome builds=stillFail %]
|
||||
[% END %]
|
||||
|
||||
[% IF stillSucceed.size > 0 %]
|
||||
<tr><th class="subheader" colspan="0">Builds that still <strong>succeed</strong></th></tr>
|
||||
[% INCLUDE renderSome builds=stillSucceed %]
|
||||
[% END %]
|
||||
|
||||
[% INCLUDE renderBuildListFooter %]
|
||||
|
||||
[% END %]
|
47
src/root/jobset-evals.tt
Normal file
47
src/root/jobset-evals.tt
Normal file
@ -0,0 +1,47 @@
|
||||
[% WRAPPER layout.tt title="Jobset ‘$project.name:$jobset.name’ evaluations" %]
|
||||
[% PROCESS common.tt %]
|
||||
|
||||
<h1>Evaluations of Jobset <tt>[% INCLUDE renderLink
|
||||
uri = c.uri_for(c.controller('Project').action_for('view'), [project.name])
|
||||
title = project.name %]:[% jobset.name %]</tt></h1>
|
||||
|
||||
<p>Showing evaluations [% (page - 1) * resultsPerPage + 1 %] - [%
|
||||
(page - 1) * resultsPerPage + evals.size %] out of [% total %].</p>
|
||||
|
||||
[% INCLUDE renderPager %]
|
||||
|
||||
<table class="tablesorter">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>Date</th>
|
||||
<th colspan='2'>Success</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
[% last = evals.size - 2; FOREACH n IN [0..last]; eval = evals.$n; m = n + 1; next = evals.$m; %]
|
||||
<tr>
|
||||
<td><a href="[% c.uri_for(c.controller('JobsetEval').action_for('view'), [eval.id]) %]">[% eval.id %]</a> </td>
|
||||
<td>[% INCLUDE renderDateTime timestamp = eval.timestamp %] </td>
|
||||
<td align='right'>
|
||||
[% eval.get_column('nrSucceeded') %] / [% eval.get_column('nrBuilds') %]
|
||||
[% IF eval.get_column('nrScheduled') > 0 %]
|
||||
<br />[% eval.get_column('nrScheduled') %] scheduled
|
||||
[% END %]
|
||||
</td>
|
||||
<td align='right'>
|
||||
[% diff = eval.get_column('nrSucceeded') - next.get_column('nrSucceeded');
|
||||
IF diff > 0 %]
|
||||
<span class='green'><strong>+[% diff %]</strong></span>
|
||||
[% ELSIF diff < 0 && eval.get_column('nrScheduled') == 0 %]
|
||||
<span class='red'><strong>[% diff %]</strong></span>
|
||||
[% END %]
|
||||
</td>
|
||||
</tr>
|
||||
[% END %]
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
[% INCLUDE renderPager %]
|
||||
|
||||
[% END %]
|
@ -44,6 +44,9 @@
|
||||
[% INCLUDE makeLink
|
||||
uri = c.uri_for(c.controller('Jobset').action_for('index'), [project.name, jobset.name])
|
||||
title = "Overview" %]
|
||||
[% INCLUDE makeLink
|
||||
uri = c.uri_for(c.controller('Jobset').action_for('evals'), [project.name, jobset.name])
|
||||
title = "Evaluations" %]
|
||||
[% INCLUDE makeLink
|
||||
uri = c.uri_for(c.controller('Jobset').action_for('all'), [project.name, jobset.name])
|
||||
title = "All builds" %]
|
||||
|
@ -38,7 +38,14 @@ th, td {
|
||||
}
|
||||
|
||||
th {
|
||||
background-color:#E6EEEE;
|
||||
background-color: #E6EEEE;
|
||||
}
|
||||
|
||||
th.subheader {
|
||||
background-color: #f0f0f8;
|
||||
font-size: 120%;
|
||||
text-align: center;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
table.tablesorter:not(.clean) tr:nth-child(even) {
|
||||
|
Reference in New Issue
Block a user