summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksander Mistewicz <a.mistewicz@samsung.com>2016-10-13 15:55:21 +0200
committerAleksander Mistewicz <a.mistewicz@samsung.com>2017-01-10 10:49:05 +0100
commit9d42a7b83449ef1a1e83a86a305388d5c6e33669 (patch)
tree1d447f90608775f01f0f3a6be21485b8acaab522
parent8aa01967a4ed3dd567f0ab4ab1ca290e3d04a302 (diff)
downloadmajor-9d42a7b83449ef1a1e83a86a305388d5c6e33669.tar.gz
major-9d42a7b83449ef1a1e83a86a305388d5c6e33669.tar.bz2
major-9d42a7b83449ef1a1e83a86a305388d5c6e33669.zip
Link screenshot only if in a set of screenshotable
Change-Id: Ica1f8f443bf02ed4a6e9719df4a20a20b10b2147 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
-rwxr-xr-xtsp/scripts/publish.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/tsp/scripts/publish.py b/tsp/scripts/publish.py
index 62f3232..a08ec0e 100755
--- a/tsp/scripts/publish.py
+++ b/tsp/scripts/publish.py
@@ -22,7 +22,7 @@ import argparse
import sqlite3
import jinja2
-__version__ = "0.0.2"
+__version__ = "0.0.3"
__license__ = "APACHE-2.0"
__author__ = "Aleksander Mistewicz"
__author_email__ = "a.mistewicz@samsung.com"
@@ -32,6 +32,7 @@ USAGE = "%prog <db>"
AGENT = "%s/%s" % (__name__, __version__)
COLORS = ["#fff", "#ddd"]
+SCREENSHOTABLE = ["odroid", "artik5", "artik10", "artik5"]
def print_head(row):
template = jinja2.Template('<tr>\n\
@@ -55,14 +56,14 @@ def print_row(row, color):
{% if status == \'OK\' or status == \'Unclear\' or status == \'Fail\' or status == \'Snapshot\' %}\
(<a href=\"../img_test/{{ build_nr }}/sysctl.result\">smoke</a>,\
<a href=\"../img_test/{{ build_nr }}/avocado-results/latest/html/results.html\">avocado</a>\
-{% if target == \'odroid\' %}\
+{% if target in screenshotable %}\
, <a href=\"../img_test/{{ build_nr }}/screenshot.png\">screenshot</a>\
{% endif %})\
{% endif %}\
</td>\n\
</tr>\n')
print template.render(build_nr=build_nr, sr=sr, row=[date, build_nr, target],\
- status=status, target=target, color=color)
+ status=status, target=target, color=color, screenshotable=SCREENSHOTABLE)
def print_view(dbpath):
def next_color(col):