[2.7.1] Test NSFaultManagement-API.Alarms Incorrect Schema validation.
The plugtest validates faultDetails as type 'String'. However, as per the SOL005 2.7.1 spec, the type should be an array-of-string. The screenshot attached depicts the cardinality to be "0..N".
Rest Invocation (Plugtest logs)
13:32:10.314 DEBUG "GET /telco/api/nsfm/v2/alarms HTTP/1.1" 200 None 13:32:10.317 TRACE Return: {'body': [{'_links': {'self': {'href': '/telco/api/nsfm/v2/alarms/a761571b-91b8-478e-946c-7b3497eabb65'}}, 'ackState': 'UNACKNOWLEDGED', 'alarmRaisedTime': 'Sat Jul 24 00:16:49 GMT 2021', 'eventTime': 'Sat Jul 24 00:17:58 GMT 2021', 'eventType': 'PROCESSING_ERROR_ALARM', 'faultDetails': ['Cannot find vnfInstance Name for vnfInstanceId:"803d3a8c-9957-4c33-8fba-a13c729c0c5b" of an alarm with id:"a761571b-91b8-478e-946c-7b3497eabb65"'], 'faultType': 'Failed to create number of replica(s) after specified number of tries', 'id': 'a761571b-91b8-478e-946c-7b3497eabb65', 'isRootCause': True, 'managedObjectId': '803d3a8c-9957-4c33-8fba-a13c729c0c5b', 'perceivedSeverity': 'WARNING', 'probableCause': 'ProgressDeadlineExceeded'}, {'_links': {'self': {'href': '/telco/api/nsfm/v2/alarms/b85dba2e-978c-4d11-94dd-642b4270c719'}}, 'ackState': 'UNACKNOWLEDGED', 'alarmRaisedTime': 'Sat Jul 24 01:22:35 GMT 2021', 'eventTime': 'Sat Jul 24 01:22:59 GMT 2021', 'eventType': 'PROCESSING_ERROR_ALARM', 'faultDetails': ['Cannot find vnfInstance Name for vnfInstanceId:"1ad2ee08-50d7-4a96-8288-9c1811467c91" of an alarm with id:"b85dba2e-978c-4d11-94dd-642b4270c719"'], 'faultType': 'Failed to create number of replica(s) after specified number of tries', 'id': 'b85dba2e-978c-4d11-94dd-642b4270c719', 'isRootCause': True, 'managedObjectId': '1ad2ee08-50d7-4a96-8288-9c1811467c91', 'perceivedSeverity': 'WARNING', 'probableCause': 'ProgressDeadlineExceeded'}, {'_links': {'self': {'href': '/telco/api/nsfm/v2/alarms/83e7ed6f-ccd1-4198-a102-55fee45fe7f7'}}, 'ackState': 'ACKNOWLEDGED', 'alarmRaisedTime': 'Sat Jul 24 04:12:31 GMT 2021', 'eventTime': 'Sat Jul 24 04:13:00 GMT 2021', 'eventType': 'PROCESSING_ERROR_ALARM', 'faultDetails': ['Cannot find vnfInstance Name for vnfInstanceId:"383f176d-f592-4b49-88dd-3ac69edb3587" of an alarm with id:"83e7ed6f-ccd1-4198-a102-55fee45fe7f7"'], 'faultType': 'Failed to create number of replica(s) after specified number of tries', 'id': '83e7ed6f-ccd1-4198-a102-55fee45fe7f7', 'isRootCause': True, 'managedObjectId': '383f176d-f592-4b49-88dd-3ac69edb3587', 'perceivedSeverity': 'WARNING', 'probableCause': 'ProgressDeadlineExceeded'}, {'_links': {'self': {'href': '/telco/api/nsfm/v2/alarms/109d8d61-7e60-45ff-a3f7-506087fb2ad6'}}, 'ackState': 'UNACKNOWLEDGED', 'alarmRaisedTime': 'Sat Jul 24 04:02:27 GMT 2021', 'eventTime': 'Mon Jul 26 18:12:31 GMT 2021', 'eventType': 'PROCESSING_ERROR_ALARM', 'faultDetails': ['Cannot find vnfInstance Name for vnfInstanceId:"383f176d-f592-4b49-88dd-3ac69edb3587" of an alarm with id:"109d8d61-7e60-45ff-a3f7-506087fb2ad6"'], 'faultType': 'Failed to pull image from docker repository', 'id': '109d8d61-7e60-45ff-a3f7-506087fb2ad6', 'isRootCause': True, 'managedObjectId': '383f176d-f592-4b49-88dd-3ac69edb3587', 'perceivedSeverity': 'CRITICAL', 'probableCause': 'ErrImagePull'}], 'headers': {'Cache-Control': 'no-cache, no-store, max-age=0, must-revalidate', 'Connection': 'Keep-Alive', 'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 23 Sep 2021 08:02:09 GMT', 'Expires': '0', 'Keep-Alive': 'timeout=5, max=100', 'Pragma': 'no-cache', 'Server': 'Apache', 'Set-Cookie': 'SESSION=c83359a4-9afd-464d-9833-bab15d0f1d4b; Path=/; Secure; HttpOnly', 'Strict-Transport-Security': 'max-age=31536000 ; includeSubDomains', 'Transfer-Encoding': 'chunked', 'Version': '2.7.1', 'X-Content-Type-Options': 'nosniff', 'X-Frame-Options': 'SAMEORIGIN', 'X-XSS-Protection': '1; mode=block', 'vary': 'accept-encoding', 'x-transaction-id': 'efdf095a-b6e5-41a6-9831-9849da30a2c5'}, 'seconds': 0.20025800000000002, 'status': 200}
Test Logs:
13:32:10.342 FAIL ValidationError: Validation error for schema alarms.schema.json: ['Cannot find vnfInstance Name for vnfInstanceId:"803d3a8c-9957-4c33-8fba-a13c729c0c5b" of an alarm with id:"a761571b-91b8-478e-946c-7b3497eabb65"'] is not of type 'string'
SOL Spec Screenshot
Edited by banerjeesu