"proto3/git@forge.etsi.org:mec/gs029-fai-api.git" did not exist on "3b6ec10ebb8950501482fa9decf0b0d8922862da"
Newer
Older
*** Settings ***
Documentation
... A test suite for validating Application Subscriptions (APPSUB) operations.
Resource ../../GenericKeywords.robot
Resource environment/variables.txt
Library REST ${SCHEMA}://${HOST}:${PORT} ssl_verify=false
Library OperatingSystem
[Documentation]
... Check that the IUT responds with a list of subscriptions for notifications
... on services availability when queried by a MEC Application
...
... Reference ETSI GS MEC 011 V2.1.1, clause 7.2.3.3.1
... OpenAPI https://forge.etsi.org/rep/mec/gs011-app-enablement-api/blob/master/MecAppSupportApi.yaml#/definitions/MecAppSuptApiSubscriptionLinkList
Check HTTP Response Body Json Schema Is AppTerminationNotificationSubscription
[Documentation]
... Check that the IUT responds with an error when
... a request for an unknown URI is sent by a MEC Application
...
... Reference ETSI GS MEC 011 V2.1.1, clause 7.2.3.3.1
Get Subscriptions list ${NON_EXISTENT_APP_INSTANCE_ID}
Check HTTP Response Status Code Is 404
[Documentation]
... Check that the IUT acknowledges the subscription by a MEC Application
... to notifications on service availability events
...
... Reference ETSI GS MEC 011 V2.1.1, clause 7.2.3.3.4
... OpenAPI https://forge.etsi.org/rep/mec/gs011-app-enablement-api/blob/master/MecAppSupportApi.yaml#/definitions/AppTerminationNotificationSubscription
Create new subscription ${APP_INSTANCE_ID} AppTerminationNotificationSubscription
Check HTTP Response Status Code Is 201
Check HTTP Response Body Json Schema Is AppTerminationNotificationSubscription
Check HTTP Response Header Contains Location
Check Response Contains ${response['body']} subscriptionType AppTerminationNotificationSubscription
Check Response Contains ${response['body']} callbackReference ${APP_TERM_NOTIF_CALLBACK_URI}
[Documentation]
... Check that the IUT responds with the information on a specific subscription
... when queried by a MEC Application
...
... Reference ETSI GS MEC 011 V2.1.1, clause 7.2.4.3.1
... OpenAPI https://forge.etsi.org/rep/mec/gs011-app-enablement-api/blob/master/MecAppSupportApi.yaml#/definitions/AppTerminationNotificationSubscription
Get individual subscription ${APP_INSTANCE_ID} ${SUBSCRIPTION_ID}
Check HTTP Response Status Code Is 200
Check HTTP Response Body Json Schema Is AppTerminationNotificationSubscription
Check Response Contains ${response['body']} subscriptionType AppTerminationNotificationSubscription
[Documentation]
... Check that the IUT responds with an error when
... a request for an unknown URI is sent by a MEC Application
...
... Reference ETSI GS MEC 011 V2.1.1, clause 7.2.4.3.1
Get individual subscription ${APP_INSTANCE_ID} ${NON_EXISTENT_SUBSCRIPTION_ID}
Check HTTP Response Status Code Is 404
[Documentation]
... Check that the IUT acknowledges the unsubscribe from service availability event notifications
... when commanded by a MEC Application
...
... Reference ETSI GS MEC 011 V2.1.1, clause 7.2.4.3.5
Remove subscription ${APP_INSTANCE_ID} ${SUBSCRIPTION_ID}
Check HTTP Response Status Code Is 204
[Documentation]
... Check that the IUT responds with an error when
... a request for an unknown URI is sent by a MEC Application
...
... Reference ETSI GS MEC 011 V2.0.9, clause 7.2.4.3.5
[Tags] PIC_MEC_PLAT PIC_SERVICES
Remove subscription ${NON_EXISTENT_APP_INSTANCE_ID} ${SUBSCRIPTION_ID}
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
*** Keywords ***
Get Subscriptions List
[Arguments] ${appInstanceId}
Set Headers {"Accept":"application/json"}
Set Headers {"Authorization":"${TOKEN}"}
Get ${apiRoot}/${apiName}/${apiVersion}/applications/${appInstanceId}/subscriptions
${output}= Output response
Set Suite Variable ${response} ${output}
Create new subscription
[Arguments] ${appInstanceId} ${content}
Set Headers {"Accept":"application/json"}
Set Headers {"Content-Type":"application/json"}
Set Headers {"Authorization":"${TOKEN}"}
${file}= Catenate SEPARATOR= jsons/ ${content} .json
${body}= Get File ${file}
Post ${apiRoot}/${apiName}/${apiVersion}/applications/${appInstanceId}/subscriptions ${body}
${output}= Output response
Set Suite Variable ${response} ${output}
Get individual subscription
[Arguments] ${appInstanceId} ${subscriptionId}
Set Headers {"Accept":"application/json"}
Set Headers {"Authorization":"${TOKEN}"}
Get ${apiRoot}/${apiName}/${apiVersion}/applications/${appInstanceId}/subscriptions/${subscriptionId}
${output}= Output response
Set Suite Variable ${response} ${output}
Remove subscription
[Arguments] ${appInstanceId} ${subscriptionId}
Set Headers {"Accept":"application/json"}
Set Headers {"Authorization":"${TOKEN}"}
Delete ${apiRoot}/${apiName}/${apiVersion}/applications/${appInstanceId}/subscriptions/${subscriptionId}
${output}= Output response
Set Suite Variable ${response} ${output}