Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
NFV - Network Functions Virtualisation
api-tests
Commits
3289ba78
Commit
3289ba78
authored
Feb 12, 2021
by
Giacomo Bernini
Browse files
updated authorization header and token use in SOL003 v2.7.1
parent
bf39094b
Changes
46
Expand all
Hide whitespace changes
Inline
Side-by-side
SOL003/VNFPerformanceManagement-API/Thresholds.robot
View file @
3289ba78
...
...
@@ -140,7 +140,7 @@ GET Performance Thresholds - Bad Request Response too Big
GET all Performance Thresholds
Log
Trying to get all thresholds present in the VNFM
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
GET
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/thresholds
${output}
=
Output
response
Set Suite Variable
${response}
${output}
...
...
@@ -148,7 +148,7 @@ GET all Performance Thresholds
GET Performance Thresholds with attribute-based filter
Log
Trying to get thresholds present in the VNFM with filter
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
GET
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/thresholds?
${FILTER_OK}
${output}
=
Output
response
Set Suite Variable
${response}
${output}
...
...
@@ -156,7 +156,7 @@ GET Performance Thresholds with attribute-based filter
GET Performance Thresholds with invalid attribute-based filter
Log
Trying to get thresholds present in the VNFM with invalid filter
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
GET
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/thresholds?
${FILTER_KO}
${output}
=
Output
response
Set Suite Variable
${response}
${output}
...
...
@@ -164,14 +164,14 @@ GET Performance Thresholds with invalid attribute-based filter
GET VNF Performance Thresholds with invalid resource endpoint
Log
Trying to get thresholds present in the VNFM with invalid resource endpoint
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
GET
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/threshold
${output}
=
Output
response
Set Suite Variable
${response}
${output}
Send Post Request Create new Performance Threshold
Log
Creating a new THreshold
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Set Headers
{"Content-Type": "
${CONTENT_TYPE_JSON}
"}
${template}
=
Get File
jsons/CreateThresholdRequest.json
...
...
@@ -182,7 +182,7 @@ Send Post Request Create new Performance Threshold
Send PUT Request for all Performance Thresholds
Log
PUT THresholds
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Set Headers
{"Content-Type": "
${CONTENT_TYPE_JSON}
"}
PUT
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/thresholds
...
...
@@ -191,7 +191,7 @@ Send PUT Request for all Performance Thresholds
Send PATCH Request for all Performance Thresholds
Log
PUT THresholds
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Set Headers
{"Content-Type": "
${CONTENT_TYPE_JSON}
"}
PATCH
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/thresholds
...
...
@@ -200,7 +200,7 @@ Send PATCH Request for all Performance Thresholds
Send DELETE Request for all Performance Thresholds
Log
DELETE THresholds
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
DELETE
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/thresholds
${output}
=
Output
response
Set Suite Variable
${response}
${output}
...
...
@@ -212,7 +212,7 @@ Check Postcondition Thresholds Exist
Check Postcondition Threshold Exists
Log
Checking that Threshold exists
Set Headers
{"Accept": "
${ACCEPT_JSON}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
Authorization
":
"
${AUTHORIZATION}
"}
Run Keyword If
${AUTH_USAGE}
=
= 1
Set Headers
{"
${AUTHORIZATION_HEADER}
":"
${AUTHORIZATION
_TOKEN
}
"}
GET
${apiRoot}
/
${apiName}
/
${apiMajorVersion}
/thresholds/
${response['body']['id']}
${output}
=
Output
response
Set Suite Variable
${response}
${output}
...
...
SOL003/VNFPerformanceManagement-API/environment/variables.txt
View file @
3289ba78
...
...
@@ -4,7 +4,8 @@ ${VNFM_PORT} 8080 # Listening port of the VNFM
${VNFM_SCHEMA} https
${AUTHORIZATION} Bearer 0b79bab50daca910b000d4f1a2b675d604257e42
${AUTHORIZATION_HEADER} Authorization
${AUTHORIZATION_TOKEN} Bearer 0b79bab50daca910b000d4f1a2b675d604257e42
${NEG_AUTHORIZATION} Bearer negativetoken
${CONTENT_TYPE_JSON} application/json
...
...
SOL003/VirtualisedResourcesQuotaAvailableNotification-API/ApiVersion.robot
View file @
3289ba78
This diff is collapsed.
Click to expand it.
SOL003/VirtualisedResourcesQuotaAvailableNotification-API/NotificationConsumer.robot
View file @
3289ba78
This diff is collapsed.
Click to expand it.
SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot
View file @
3289ba78
This diff is collapsed.
Click to expand it.
SOL003/VirtualisedResourcesQuotaAvailableNotification-API/environment/variables.txt
View file @
3289ba78
...
...
@@ -2,7 +2,8 @@
${NFVO_HOST} localhost # Hostname of the NFVO
${NFVO_PORT} 8081 # Listening port of the NFVO
${NFVO_SCHEMA} https
${AUTHORIZATION} Bearer QWxhZGRpbjpvcGVuIHNlc2FtZQ==
${AUTHORIZATION_HEADER} Authorization
${AUTHORIZATION_TOKEN} Bearer 0b79bab50daca910b000d4f1a2b675d604257e42
${CONTENT_TYPE} application/json
${AUTH_USAGE} 1
${ACCEPT} application/json
...
...
Prev
1
2
3
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment