DBNAME="results.db3"
DBPATH="${WS_PUBLISH}/${DBNAME}"
WWW_PUBLISH="${WS_PUBLISH}/current_status.html"
+WWW_3_PUBLISH="${WS_PUBLISH}/current_status_3.html"
TMP_POLL="/tmp/tl-master-poll"
TMP_MASTER="/tmp/tl-master"
"${TSP_DIR}/scripts/publish.py" "${DBPATH}"
cat "${TSP_DIR}/html_tail"
} > "${WWW_PUBLISH}"
+
+# Publish to www_3
+{
+ cat "${TSP_DIR}/html_head"
+ lockfile-create --use-pid "${DBPATH}"
+ "${TSP_DIR}/scripts/publish.py" --tizen3 "${DBPATH}"
+ lockfile-remove "${DBPATH}"
+ cat "${TSP_DIR}/html_tail"
+} > "${WWW_3_PUBLISH}"
INNER JOIN result ON result.rid = test.trid
ORDER BY SR DESC
;
+
+CREATE VIEW IF NOT EXISTS currentstatus3 AS
+ SELECT
+ test.tnumber AS "SR",
+ test.tdate AS "Date",
+ test.tbuildnr AS "Build nr",
+ device.dname AS "Device",
+ result.rname AS "Status"
+ FROM test
+ INNER JOIN device ON test.tdid = device.did
+ INNER JOIN result ON result.rid = test.trid
+ WHERE SR LIKE "%3.0-common%"
+ ORDER BY SR DESC
+;
conn = sqlite3.connect(dbpath)
column_names = ["SR", "Date", "\"Build nr\"", "Device", "Status"]
print_head(column_names)
- testresults = conn.execute("SELECT " + ', '.join(column_names) + " FROM currentstatus;")
+ if tizen3:
+ testresults = conn.execute("SELECT " + ', '.join(column_names) + " FROM currentstatus3;")
+ else:
+ testresults = conn.execute("SELECT " + ', '.join(column_names) + " FROM currentstatus;")
col = COLORS[0]
prev_sr = ''
for row in testresults:
sr=row[0]
- if tizen3 and not '-3.0-' in sr:
- continue
if not sr == prev_sr:
prev_sr = sr
col = next_color(col)
parser.add_argument("-3", "--tizen3",
action="store_true", dest="tizen3",
- help='Print results for Tizen 3.0 only')
+ help='Print results for Tizen 3.0-common only')
args = parser.parse_args()