-
Notifications
You must be signed in to change notification settings - Fork 243
/
Copy pathindex.jinja2
183 lines (170 loc) · 5.58 KB
/
index.jinja2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/echarts.min.js"></script>
<title id="head-title">{{ title }}</title>
{%- if self_contained %}
<style type="text/css">
{{- styles|safe }}
</style>
{% else %}
<link href="{{ styles }}" rel="stylesheet" type="text/css"/>
{%- endif %}
</head>
<body>
<h1 id="title">{{ title }}</h1>
<p>{{ date }} at {{ time }} </p>
<div id="main" style="width: 550px;height:400px;"></div>
<!-- END TEMPLATES -->
<div class="summary">
<div class="summary__data">
<div class="additional-summary prefix">
{%- for p in additional_summary['prefix'] %}
{{ p|safe }}
{%- endfor %}
</div>
<p class="run-count">{{ run_count }}</p>
<div class="summary__reload">
<div class="summary__reload__button {{ 'hidden' if running_state == 'finished' }}"
onclick="location.reload()">
<div>There are still tests running. <br/>Reload this page to get the latest results!</div>
</div>
</div>
<div class="summary__spacer"></div>
<div class="controls">
<div class="filters">
{%- for result, values in outcomes.items() %}
<input checked="true" class="filter" name="filter_checkbox" type="checkbox"
data-test-result="{{ result }}" {{ "disabled" if values["value"] == 0 }}/>
<span class="{{ result }}">{{ values["value"] }}
{{ values["label"] }}{{ "," if result != "rerun" }}</span>
{%- endfor %}
</div>
<div class="collapse">
<button id="show_all_details">Show all details</button> / <button id="hide_all_details">Hide
all details
</button>
</div>
</div>
</div>
<div class="additional-summary summary">
{%- for s in additional_summary['summary'] %}
{{ s|safe }}
{%- endfor %}
</div>
<div class="additional-summary postfix">
{%- for p in additional_summary['postfix'] %}
{{ p|safe }}
{%- endfor %}
</div>
</div>
<table id="results-table">
<thead id="results-table-head">
<tr>
{%- for th in table_head %}
{{ th|safe }}
{%- endfor %}
</tr>
</thead>
</table>
<div>
<div id="environment-header">
<h2>Environment</h2>
</div>
<table id="environment"></table>
<!-- TEMPLATES -->
<template id="template_environment_row">
<tr>
<td></td>
<td></td>
</tr>
</template>
<template id="template_results-table__body--empty">
<tbody class="results-table-row">
<tr id="not-found-message">
<td colspan="{{ table_head|length }}">No results found. Check the filters.</th>
</tr>
</template>
<template id="template_results-table__tbody">
<tbody class="results-table-row">
<tr class="collapsible">
</tr>
<tr class="extras-row">
<td class="extra" colspan="{{ table_head|length }}">
<div class="extraHTML"></div>
<div class="media">
<div class="media-container">
<div class="media-container__nav--left"><</div>
<div class="media-container__viewport">
<img src=""/>
<video controls>
<source src="" type="video/mp4">
</video>
</div>
<div class="media-container__nav--right">></div>
</div>
<div class="media__name"></div>
<div class="media__counter"></div>
</div>
<div class="logwrapper">
<div class="logexpander"></div>
<div class="log"></div>
</div>
</td>
</tr>
</tbody>
</template>
</div>
<script type="text/javascript">
let chatData = []
{%- for result, values in outcomes.items() %}
chatData.push({value: {{values["value"]}}, name: '{{result}}'})
{%- endfor %}
var chartDom = document.getElementById('main');
var myChart = echarts.init(document.getElementById('main'));
var option = {
color :['#ee6666','#91cc75','#fac858','#5470c6','#fbb1a2','#859382','#da995f'],
tooltip: {
trigger: 'item'
},
legend: {
botoom: '4%',
left: 'center'
},
series: [
{
name: 'run result',
type: 'pie',
radius: ['40%', '70%'],
avoidLabelOverlap: false,
itemStyle: {
borderRadius: 10,
borderColor: '#fff',
borderWidth: 2
},
label: {
show: false,
position: 'center'
},
emphasis: {
label: {
show: true,
fontSize: 35,
fontWeight: 'bold'
}
},
data: chatData
}
]
};
myChart.setOption(option);
</script>
</body>
<footer>
<div id="data-container" data-jsonblob="{{ test_data }}"></div>
<script>
{% include "app.js" %}
</script>
</footer>
</html>