summaryrefslogtreecommitdiffstats
path: root/cvp/3rd_party/static
diff options
context:
space:
mode:
authorchenjiankun <chenjiankun1@huawei.com>2018-04-26 07:34:43 +0000
committerchenjiankun <chenjiankun1@huawei.com>2018-04-26 07:55:46 +0000
commit67de42416576c952ec0d6a159a0d57fc4cabc414 (patch)
tree5ec8c9cc7bc0a0baff5a16139a57b252d58db4e4 /cvp/3rd_party/static
parentcb02bccdef30575bb46080475ca13fdf8b6b4b2f (diff)
Extend web portal to show if API exemption was used during a test run
JIRA: DOVETAIL-634 The OVP web port needs to read from the test results if the strict API response validation exemption was used or not and show it correspondingly. Detailed description: As discussed on the Dovetail call on 2018-04-11, the web portal should show if API response validation was enabled or disabled. The information if API response validation was enabled or disabled is to be determined based on the dovetail.log file. If API response validation was disabled,** the log file contains the line "Strict API response validation DISABLED.". Upon uploading a result tar-package, the web portal should extract this information from the log file, store it in the database, and display it as follows: This indication shall be displayed along with the test summary on the Test Run Results page as either: "API response validation enabled" or "API response validation disabled" For clarification: API response validation is enabled by default. API response validation is disabled only if the --no-api-validation command line option is given. Change-Id: Ifacb1eb2127cc8dc6364c98dead1217aeedfd359 Signed-off-by: chenjiankun <chenjiankun1@huawei.com>
Diffstat (limited to 'cvp/3rd_party/static')
-rw-r--r--cvp/3rd_party/static/testapi-ui/components/results-report/resultsReport.html2
-rw-r--r--cvp/3rd_party/static/testapi-ui/components/results-report/resultsReportController.js2
2 files changed, 4 insertions, 0 deletions
diff --git a/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReport.html b/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReport.html
index 16cfa65d..bc049f31 100644
--- a/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReport.html
+++ b/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReport.html
@@ -14,6 +14,8 @@
<strong>Total: {{ctrl.statistics.total}}, Pass: {{ ctrl.statistics.pass}}, Rate: {{ ctrl.statistics.pass / ctrl.statistics.total * 100 | number:2 }}%</strong></br>
<strong>Mandatory Total: {{ctrl.statistics.mandatory.total}}, Pass: {{ ctrl.statistics.mandatory.pass }}, Rate: {{ ctrl.statistics.mandatory.pass / ctrl.statistics.mandatory.total * 100 | number:2 }}%</strong></br>
<strong>Optional Total: {{ctrl.statistics.optional.total}}, Pass: {{ ctrl.statistics.optional.pass }}, Rate: {{ ctrl.statistics.optional.pass / ctrl.statistics.optional.total * 100 | number:2 }}%</strong></br>
+<hr>
+<strong>{{ ctrl.validation }}</strong></br>
<div>
<hr>
diff --git a/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReportController.js b/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReportController.js
index b0061f61..65ce151d 100644
--- a/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReportController.js
+++ b/cvp/3rd_party/static/testapi-ui/components/results-report/resultsReportController.js
@@ -52,6 +52,7 @@
/** The testID extracted from the URL route. */
ctrl.testId = $stateParams.testID;
ctrl.innerId = $stateParams.innerID;
+ ctrl.validation = '';
/** The HTML template that all accordian groups will use. */
ctrl.detailsTemplate = 'testapi-ui/components/results-report/partials/' +
@@ -158,6 +159,7 @@
function generate_format_data() {
var test_url = testapiApiUrl + '/tests/' + ctrl.innerId;
$http.get(test_url).then(function(test_resp){
+ ctrl.validation = test_resp.data.validation;
angular.forEach(test_resp.data.results, function(result, index){
var result_url = testapiApiUrl + '/results/' + result;
$http.get(result_url).then(function(result_resp){