From 804ec686128a49628e9f656397e4a4512e4c5714 Mon Sep 17 00:00:00 2001 From: Vodafone Date: Mon, 18 Mar 2019 15:46:53 +0530 Subject: List of Input Parameters for VSP: FE Change-Id: I17697b5646c1a201678dbab11fef28a7483fbf8c Issue-ID: SDC-2049 Co-authored-by: rahul.ghugikar@vodafone.com, soumyarup.paul@vodafone.com Signed-off-by: Vodafone --- .../SoftwareProductValidationResultsFactory.js | 163 +++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 openecomp-ui/test-utils/factories/softwareProduct/SoftwareProductValidationResultsFactory.js (limited to 'openecomp-ui/test-utils/factories/softwareProduct/SoftwareProductValidationResultsFactory.js') diff --git a/openecomp-ui/test-utils/factories/softwareProduct/SoftwareProductValidationResultsFactory.js b/openecomp-ui/test-utils/factories/softwareProduct/SoftwareProductValidationResultsFactory.js new file mode 100644 index 0000000000..6728e049b0 --- /dev/null +++ b/openecomp-ui/test-utils/factories/softwareProduct/SoftwareProductValidationResultsFactory.js @@ -0,0 +1,163 @@ +/** + * Copyright (c) 2019 Vodafone Group + * + * 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 + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { Factory } from 'rosie'; + +export const VSPTestResultsFailureFactory = new Factory().attrs({ + vspTestResults: [ + { + code: '500', + message: 'VTP Test(s) could not be completed', + httpStatus: 500 + } + ] +}); + +export const VSPTestResultsSuccessFactory = new Factory().attrs({ + vspTestResults: [ + { + scenario: 'certification', + description: 'Other Certifications', + testCaseName: 'certification.certificationtests.certquery', + testSuiteName: 'certificationtests', + executionId: 'ebaa5f21-ed68-4098-97a9-775ac8800f09-1550575025614', + parameters: { + vspId: 'uuidval', + vspVersion: 'ver', + other: 'values' + }, + results: { + testResults: { + complianceTests: [ + { + testName: 'Compute Flavors', + testResult: 'Pass', + notes: + 'Diagnostic: test performed against GSMA NFVI Abstraction and Profiling Version 0.1 profiles.' + }, + { + testName: 'SR-IOV', + testResult: 'Fail', + notes: + 'Diagnostic: SR-IOV found in VNF Template. User advice: VNF binary and VNF Template must be modified to not require SR-IOV.' + }, + { + testName: 'Heat', + testResult: 'Pass', + notes: '' + }, + { + testName: 'TOSCA', + testResult: 'Pass', + notes: + 'Diagnostic: test performed for ETSI GS NFV-SOL001v0.10.0.' + } + ], + validationTests: [ + { + testName: 'OpenStack', + testResult: 'Pass', + notes: + 'Diagnostic: test performed for OpenStack Rocky.' + }, + { + testName: 'VMware', + testResult: 'Fail', + notes: + 'Diagnostic: VMware compatible template not found. User advice: add a VMware compatible template to the VSP.' + }, + { + testName: 'Kubernetes', + testResult: 'Fail', + notes: + 'Diagnostic: Kubernetes compatible template not found. User advice: add a Kubernetes compatible template, such as Helm Chart, to the VSP.' + } + ], + performanceTests: [ + { + testName: 'Max Throughput', + testResult: 'Pass', + notes: '' + }, + { + testName: 'Latency', + testResult: 'Fail', + notes: + 'Diagnostic: maximum latency threshold of 20ms signalling response time exceededUser advice: consider increasing VDU compute resource.' + } + ] + } + }, + + status: 'COMPLETED', + startTime: '2019-02-19T11:17:05.670', + endTime: '2019-02-19T11:17:05.683' + }, + { + scenario: 'compliance', + testCaseName: 'compliance.compliancetests.sriov', + description: 'Allow_SR-IOV', + testSuiteName: 'compliancetests', + executionId: 'ebaa5f21-ed68-4098-97a9-775ac8800f09-1550575025614', + parameters: { + vspId: 'uuidval', + vspVersion: 'ver', + other: 'values' + }, + results: { + errors: [ + { + attribute: '', + reason: 'Record Not Found', + advice: + 'User must query with (vspId, vspVersion) values for a certifications record that is present in the Repository', + code: 40 + }, + { + attribute: '', + reason: 'Record Not Found', + advice: + 'User must query with (vspId, vspVersion) values for a certifications record that is present in the Repository', + code: 40 + } + ] + }, + status: 'FAILED', + startTime: '2019-02-19T11:17:05.670', + endTime: '2019-02-19T11:17:05.683' + }, + { + scenario: 'compliance', + testCaseName: ' compliance.compliancetests.computeflavours', + description: 'Allow SR-IOV ', + testSuiteName: 'compliancetests', + executionId: 'ebaa5f21-ed68-4098-97a9-775ac8800f09-1550575025614', + parameters: { + vspId: 'uuidval', + vspVersion: 'ver', + other: 'values' + }, + results: {}, + status: 'COMPLETED', + startTime: '2019-02-19T11:17:05.670', + endTime: '2019-02-19T11:17:05.683' + }, + { + code: '500', + message: 'VTP Test(s) could not be completed', + httpStatus: 500 + } + ] +}); -- cgit 1.2.3-korg