VnfLcmOpOcc compliance test causes "None is not of type 'string'"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
tacker |
New
|
Medium
|
Unassigned |
Bug Description
A Tacker compliance test case fails with the error "None is not of type 'string'".
The cause of this error looks similar to the one already reported in [1], but we need to modify different code from that in order to fix this error.
[1] https:/
The detail is as below:
<Target test case>
tacker.
<Error message>
<status status="FAIL" starttime="20230912 04:54:36.835" endtime="20230912 04:54:36.898" critical=
ValidationError: Validation error for schema VnfLcmOpOcc.
<Part of API Response body>
{
"seconds": 0.0073659999999
"status": 200,
"body": {
"id": "fb63df72-
"grantId": null,
{
}
],
{
},
{
}
],
{
}
]
},
...
<Possible root cause>
In the body of API response above, the following four variables have "null" value.
- grantId
- resourceChanges > affectedVnfcs > removedStorageR
- resourceChanges > affectedVirtual
- resourceChanges > affectedVirtual
Then, these values are changed from "null" to "None" by JSON library.
On the other hand, NFV-SOL003 v2.6.1 defines these attributes as the cardinality "0...1".
This indicates the pair of key and value should be omitted and also should not exist if the value is meaningless one.
As the result, the validation check in NFV TST api-tests fails due to the mismatch of types between in response body and JSON schema.
Changed in tacker: | |
importance: | Undecided → Medium |