From 940b64dfbb9992c77d1c888719d5b30a212e8f4f Mon Sep 17 00:00:00 2001 From: Yujun Zhang Date: Tue, 11 Apr 2017 15:37:35 +0800 Subject: Implement a sample qpi report to show how to retrieve variables from benchmark results Change-Id: I479e4446c18d45d69d2f88db021f7739201104d9 Signed-off-by: Yujun Zhang --- tests/integration/compute.yaml | 4 ++- tests/integration/reports/qpi-report | 46 +++++++++++++++++++++++++++++++ tests/integration/templates/qpi-report.j2 | 18 ++++++++++++ 3 files changed, 67 insertions(+), 1 deletion(-) create mode 100644 tests/integration/reports/qpi-report create mode 100644 tests/integration/templates/qpi-report.j2 (limited to 'tests/integration') diff --git a/tests/integration/compute.yaml b/tests/integration/compute.yaml index 62f8b5db..1f5ec8dd 100644 --- a/tests/integration/compute.yaml +++ b/tests/integration/compute.yaml @@ -71,7 +71,7 @@ baseline: 102.1 - name: rsa_verify_4096 baseline: 6402.9 - register: compute_result + register: qpi_result delegate_to: localhost # Generate and publish report @@ -81,3 +81,5 @@ local_action: template src=templates/system-info.j2 dest=reports/system-info delegate_to: localhost # TODO(yujunz) push test result to testapi + - name: create qpi report + template: src=templates/qpi-report.j2 dest=reports/qpi-report diff --git a/tests/integration/reports/qpi-report b/tests/integration/reports/qpi-report new file mode 100644 index 00000000..cb9e9308 --- /dev/null +++ b/tests/integration/reports/qpi-report @@ -0,0 +1,46 @@ +Sample QPI Report + +Host: node-26 +QPI: 1.41147857985 +Spec: compute + +- SSL: 1.41147857985 + - ssl_rsa: 1.41147857985 + - rsa_sign_512: 1.25261808935 + - rsa_verify_512: 1.33973907536 + - rsa_sign_1024: 1.31933223495 + - rsa_verify_1024: 1.46972456907 + - rsa_sign_2048: 1.8615470852 + - rsa_verify_2048: 1.3683903146 + - rsa_sign_4096: 1.31537708129 + - rsa_verify_4096: 1.36510018898 + +Host: node-28 +QPI: 1.28082308651 +Spec: compute + +- SSL: 1.28082308651 + - ssl_rsa: 1.28082308651 + - rsa_sign_512: 1.13628081136 + - rsa_verify_512: 1.24882238433 + - rsa_sign_1024: 1.16100601465 + - rsa_verify_1024: 1.33382620817 + - rsa_sign_2048: 1.72057174888 + - rsa_verify_2048: 1.23917640038 + - rsa_sign_4096: 1.16846229187 + - rsa_verify_4096: 1.2384388324 + +Host: node-27 +QPI: 1.41542492777 +Spec: compute + +- SSL: 1.41542492777 + - ssl_rsa: 1.41542492777 + - rsa_sign_512: 1.25857845591 + - rsa_verify_512: 1.34193319426 + - rsa_sign_1024: 1.32097981222 + - rsa_verify_1024: 1.4807103336 + - rsa_sign_2048: 1.86378923767 + - rsa_verify_2048: 1.36600306932 + - rsa_sign_4096: 1.31635651322 + - rsa_verify_4096: 1.37504880601 diff --git a/tests/integration/templates/qpi-report.j2 b/tests/integration/templates/qpi-report.j2 new file mode 100644 index 00000000..afe9bfb8 --- /dev/null +++ b/tests/integration/templates/qpi-report.j2 @@ -0,0 +1,18 @@ +Sample QPI Report +{% for host in groups['compute'] %} +{% set qpi_result = hostvars[host].qpi_result %} + +Host: {{ hostvars[host].ansible_hostname }} +QPI: {{ qpi_result.score }} +Spec: {{ qpi_result.spec.name }} + +{% for section in qpi_result.section_results %} +- {{ section.name }}: {{ section.result.score }} +{% for metric in section.result.metric_results %} + - {{ metric.name }}: {{ metric.result.score }} +{% for workload in metric.result.workload_results %} + - {{ workload.name }}: {{ workload.score }} +{% endfor %} +{% endfor %} +{% endfor %} +{% endfor %} -- cgit 1.2.3-korg