Code Review
/
csit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Trending: Plots
[csit.git]
/
resources
/
tools
/
presentation
/
generator_cpta.py
diff --git
a/resources/tools/presentation/generator_cpta.py
b/resources/tools/presentation/generator_cpta.py
index
a11d1da
..
4304521
100644
(file)
--- a/
resources/tools/presentation/generator_cpta.py
+++ b/
resources/tools/presentation/generator_cpta.py
@@
-1,4
+1,4
@@
-# Copyright (c) 20
19
Cisco and/or its affiliates.
+# Copyright (c) 20
20
Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
@@
-359,10
+359,15
@@
def _generate_all_charts(spec, input_data):
if graph.get(u"include", None):
data = input_data.filter_tests_by_name(
if graph.get(u"include", None):
data = input_data.filter_tests_by_name(
- graph, continue_on_error=True
+ graph,
+ params=[u"type", u"result", u"tags"],
+ continue_on_error=True
)
else:
)
else:
- data = input_data.filter_data(graph, continue_on_error=True)
+ data = input_data.filter_data(
+ graph,
+ params=[u"type", u"result", u"tags"],
+ continue_on_error=True)
if data is None or data.empty:
logging.error(u"No data.")
if data is None or data.empty:
logging.error(u"No data.")
@@
-587,7
+592,7
@@
def _generate_all_charts(spec, input_data):
# Write the tables:
for job_name, csv_table in csv_tables.items():
file_name = f"{spec.cpta[u'output-file']}/{job_name}-trending"
# Write the tables:
for job_name, csv_table in csv_tables.items():
file_name = f"{spec.cpta[u'output-file']}/{job_name}-trending"
- with open(f"{file_name}.csv", u"w") as file_handler:
+ with open(f"{file_name}.csv", u"w
t
") as file_handler:
file_handler.writelines(csv_table)
txt_table = None
file_handler.writelines(csv_table)
txt_table = None
@@
-613,7
+618,7
@@
def _generate_all_charts(spec, input_data):
)
line_nr += 1
txt_table.align[u"Build Number:"] = u"l"
)
line_nr += 1
txt_table.align[u"Build Number:"] = u"l"
- with open(f"{file_name}.txt", u"w") as txt_file:
+ with open(f"{file_name}.txt", u"w
t
") as txt_file:
txt_file.write(str(txt_table))
# Evaluate result:
txt_file.write(str(txt_table))
# Evaluate result: