From f70f9377c4b8fc88efa4c9b8c938f03953475b1c Mon Sep 17 00:00:00 2001 From: piscione Date: Thu, 6 May 2021 15:12:17 +0200 Subject: [PATCH] Added robot tests for MEC028. --- MEC028/WAI/AP_INFO/WaiApInfo.robot | 81 + MEC028/WAI/AP_INFO/environment/variables.txt | 14 + MEC028/WAI/AP_INFO/schemas/ApInfo.schema.json | 777 ++++++ .../schemas/ProblemDetails.schema.json | 40 + MEC028/WAI/EXT_SUB/ExistingSubscription.robot | 120 + MEC028/WAI/EXT_SUB/environment/variables.txt | 17 + .../jsons/UpdateAssocStaSubscription.json | 11 + .../jsons/UpdateAssocStaSubscription_BR.json | 11 + .../schemas/AssocStaSubscription.schema.json | 109 + MEC028/WAI/STA_INFO/WaiStaInfo.robot | 81 + MEC028/WAI/STA_INFO/environment/variables.txt | 14 + .../schemas/ProblemDetails.schema.json | 38 + .../WAI/STA_INFO/schemas/StaInfo.schema.json | 789 ++++++ MEC028/WAI/SUB/WaiSubscription.robot | 142 + MEC028/WAI/SUB/environment/variables.txt | 18 + .../WAI/SUB/jsons/AssocStaSubscription.json | 7 + .../SUB/jsons/AssocStaSubscription_BR.json | 11 + .../schemas/AssocStaSubscription.schema.json | 109 + .../schemas/SubscriptionLinkList.schema.json | 272 ++ MEC028/outputs/log-20210506-145611.html | 2189 +++++++++++++++ MEC028/outputs/log.html | 2189 +++++++++++++++ MEC028/outputs/output-20210506-145611.xml | 1000 +++++++ MEC028/outputs/output.xml | 1000 +++++++ MEC028/outputs/report-20210506-145611.html | 2458 +++++++++++++++++ MEC028/outputs/report.html | 2458 +++++++++++++++++ 25 files changed, 13955 insertions(+) create mode 100644 MEC028/WAI/AP_INFO/WaiApInfo.robot create mode 100644 MEC028/WAI/AP_INFO/environment/variables.txt create mode 100644 MEC028/WAI/AP_INFO/schemas/ApInfo.schema.json create mode 100644 MEC028/WAI/AP_INFO/schemas/ProblemDetails.schema.json create mode 100644 MEC028/WAI/EXT_SUB/ExistingSubscription.robot create mode 100644 MEC028/WAI/EXT_SUB/environment/variables.txt create mode 100644 MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription.json create mode 100644 MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription_BR.json create mode 100644 MEC028/WAI/EXT_SUB/schemas/AssocStaSubscription.schema.json create mode 100644 MEC028/WAI/STA_INFO/WaiStaInfo.robot create mode 100644 MEC028/WAI/STA_INFO/environment/variables.txt create mode 100644 MEC028/WAI/STA_INFO/schemas/ProblemDetails.schema.json create mode 100644 MEC028/WAI/STA_INFO/schemas/StaInfo.schema.json create mode 100644 MEC028/WAI/SUB/WaiSubscription.robot create mode 100644 MEC028/WAI/SUB/environment/variables.txt create mode 100644 MEC028/WAI/SUB/jsons/AssocStaSubscription.json create mode 100644 MEC028/WAI/SUB/jsons/AssocStaSubscription_BR.json create mode 100644 MEC028/WAI/SUB/schemas/AssocStaSubscription.schema.json create mode 100644 MEC028/WAI/SUB/schemas/SubscriptionLinkList.schema.json create mode 100644 MEC028/outputs/log-20210506-145611.html create mode 100644 MEC028/outputs/log.html create mode 100644 MEC028/outputs/output-20210506-145611.xml create mode 100644 MEC028/outputs/output.xml create mode 100644 MEC028/outputs/report-20210506-145611.html create mode 100644 MEC028/outputs/report.html diff --git a/MEC028/WAI/AP_INFO/WaiApInfo.robot b/MEC028/WAI/AP_INFO/WaiApInfo.robot new file mode 100644 index 0000000..c89f062 --- /dev/null +++ b/MEC028/WAI/AP_INFO/WaiApInfo.robot @@ -0,0 +1,81 @@ +''[Documentation] robot --outputdir ../../outputs ./WaiApInfo.robot +... Test Suite to validate WLAN Information API (AP_INFO) operations. + +*** Settings *** +Resource environment/variables.txt +Resource ../../../pics.txt +Resource ../../../GenericKeywords.robot +Library String +Library OperatingSystem +Library REST ${MEC-APP_SCHEMA}://${MEC-APP_HOST}:${MEC-APP_PORT} ssl_verify=false + + +*** Test Cases *** +TP_MEC_MEC028_SRV_WAI_001_OK + [Documentation] + ... Check that the IUT responds with the list of WLAN Access Point + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.3.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/ApInfo + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the access point information + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is ApInfo + ## Post condition + FOR ${apInfo} IN @{response['body']} + ${passed} Run Keyword And Return Status Should Be Equal As Strings ${apInfo['apId']['macId']} ${MAC_ID} + Exit For Loop If ${passed} + END + Should Be True ${passed} + +TP_MEC_MEC028_SRV_WAI_002_OK + [Documentation] + ... Check that the IUT responds with the list of WLAN Access Point filtered by the macId provided as query parameter + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.3.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/ApInfo + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the access point information using filters ${filter} + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is ApInfo + ## Post condition + FOR ${apInfo} IN @{response['body']} + ${passed} Run Keyword And Return Status Should Be Equal As Strings ${apInfo['apId']['macId']} ${MAC_ID} + Exit For Loop If ${passed} + END + Should Be True ${passed} + + +TP_MEC_MEC028_SRV_WAI_002_BR + [Documentation] + ... Check that the IUT responds with an error when a request with incorrect parameters is sent by a MEC Application + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.3.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/ApInfo + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the access point information using filters ${bad_filter} + Check HTTP Response Status Code Is 400 + Check HTTP Response Body Json Schema Is ProblemDetails + + +*** Keywords *** +Retrieve the access point information + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + GET ${apiRoot}/${apiName}/${apiVersion}/queries/ap/ap_information + ${output}= Output response + Set Suite Variable ${response} ${output} + +Retrieve the access point information using filters + [Arguments] ${filter} + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + GET ${apiRoot}/${apiName}/${apiVersion}/queries/ap/ap_information?filter=${filter} + ${output}= Output response + Set Suite Variable ${response} ${output} \ No newline at end of file diff --git a/MEC028/WAI/AP_INFO/environment/variables.txt b/MEC028/WAI/AP_INFO/environment/variables.txt new file mode 100644 index 0000000..ec621fe --- /dev/null +++ b/MEC028/WAI/AP_INFO/environment/variables.txt @@ -0,0 +1,14 @@ +*** Variables *** +${apiRoot} +${apiName} wai +${apiVersion} v1 + +${MEC-APP_SCHEMA} http +${MEC-APP_HOST} 127.0.0.1 +${MEC-APP_PORT} 8082 + +${TOKEN} Basic YWxhZGRpbjpvcGVuc2VzYW1l + +${MAC_ID} macId01 +${filter} (eq,apId/macId,macId01) +${bad_filter} (eq,apId/mac,macId01) \ No newline at end of file diff --git a/MEC028/WAI/AP_INFO/schemas/ApInfo.schema.json b/MEC028/WAI/AP_INFO/schemas/ApInfo.schema.json new file mode 100644 index 0000000..19cc713 --- /dev/null +++ b/MEC028/WAI/AP_INFO/schemas/ApInfo.schema.json @@ -0,0 +1,777 @@ +{ + "items": { + "properties": { + "apId": { + "properties": { + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the Access Point.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique Identifier assigned to an Access Point (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks including Basic Service Set and Extended Service Set.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.3" + }, + "apLocation": { + "properties": { + "civicLocation": { + "properties": { + "ca0": { + "description": "Language", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca1": { + "description": "National subdivisions (state, canton, region,province, prefecture) ", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca128": { + "description": "Script", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca16": { + "description": "Leading street direction", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca17": { + "description": "Trailing street suffix", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca18": { + "description": "Street suffix or type", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca19": { + "description": "House number", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca2": { + "description": "County, parish, gun (JP), district (IN)", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca20": { + "description": "House number suffix", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca21": { + "description": "Landmark of vanity address", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca22": { + "description": "Additional location information", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca23": { + "description": "Name (residence and office occupant)", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca24": { + "description": "Postal/zip code", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca25": { + "description": "Building (structure)", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca26": { + "description": "Unit (apartment/suite)", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca27": { + "description": "Floor", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca28": { + "description": "Room", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca29": { + "description": "Type of place", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca3": { + "description": "City, township, shi (JP)", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca30": { + "description": "Postal community name", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca31": { + "description": "Post office box", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca32": { + "description": "Additional code", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca33": { + "description": "Seat (desk.cubicle, workstation)", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca34": { + "description": "Primary road name", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca35": { + "description": "Road section", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca36": { + "description": "Branch road name", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca37": { + "description": "Sub-branch road name", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca38": { + "description": "Street name pre-modifier", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca39": { + "description": "Street name post-modifier", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca4": { + "description": "City division, borough, city district, ward, chou (JP)", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca5": { + "description": "Neighborhood, block", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ca6": { + "description": "Group of streets below the neighborhood level ", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "country": { + "description": "The two-letter ISO 3166 [i.9] country code in capital ASCII letters, e.g. DE or US, as per ISO 3166 [i.9]", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "country" + ], + "type": "object", + "x-etsi-ref": "6.5.20" + }, + "geolocation": { + "properties": { + "altitude": { + "description": "The altitude value of location as defined in IETF RFC 6225 [6]", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "altitudeType": { + "description": "The type description for altitude information e.g. floors or meters as defined in IETF RFC 6225 [6]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "altitudeUncertainty": { + "description": "The uncertainty for altitude information as defined in IETF RFC 6225 [6]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "datum": { + "description": "The datum value to express how coordinates are organized and related to real world as defined in IETF RFC 6225 [6]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "lat": { + "description": "The latitude value of location as defined in IETF RFC 6225 [6]", + "format": "int64", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint64" + }, + "latUncertainty": { + "description": "The uncertainty for Latitude information as defined in IETF RFC 6225 [6]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "long": { + "description": "The longitude value of location as defined in IETF RFC 6225 [6]", + "format": "int64", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint64" + }, + "longUncertainty": { + "description": "The uncertainty for Longitude information as defined in IETF RFC 6225 [6]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + } + }, + "required": [ + "latUncertainty", + "lat", + "longUncertainty", + "long", + "datum" + ], + "type": "object", + "x-etsi-ref": "6.5.19" + } + }, + "type": "object", + "x-etsi-ref": "6.5.9" + }, + "apNeighbor": { + "properties": { + "bssid": { + "description": "BSS Id of the Access Point that is being reported.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "bssidInfo": { + "description": "Additional information related to Access Point that is being reported such as AP reachability, security, key scope, Mobility Domain, HT/VHT capability and Fine Time Measurements.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt32" + }, + "channel": { + "description": "The channel currently used by this Access Point.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "operatingClass": { + "description": "The channel set of the AP indicated by this BSSID.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "phyType": { + "description": "PHY type of the AP indicated by this BSSID. It is an integer value coded according to the value of the dot11PHYType.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + } + }, + "required": [ + "bssid", + "bssidInfo", + "operatingClass", + "channel", + "phyType" + ], + "type": "object", + "x-etsi-ref": "6.5.10" + }, + "bssLoad": { + "properties": { + "availAdmCap": { + "description": "Available Admission Capacity that specifies the remaining amount of medium time available via explicit admission control, in units of 32 s/s.", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint16" + }, + "channelUtilization": { + "description": "The percentage of time, linearly scaled with 255 representing 100 %, that the AP sensed the medium was busy, as indicated by either the physical or virtual Carrier Sense (CS) mechanism.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt8" + }, + "staCount": { + "description": "An unsigned integer that indicates the total number of STAs currently associated with this BSS.", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt16" + } + }, + "required": [ + "staCount", + "channelUtilization", + "availAdmCap" + ], + "type": "object", + "x-etsi-ref": "6.5.7" + }, + "channel": { + "description": "Channel configured for the Access Point.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "extBssLoad": { + "properties": { + "muMimoStaCount": { + "description": "Indicates the total number of STAs currently associated with this BSS that have a 1 in the MU Beamformee Capable field of their VHT Capabilities element.", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt16" + }, + "obsSec20MhzUtil": { + "description": "Observable loading on each of the secondary 20 MHz channel.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "obsSec40MhzUtil": { + "description": "Observable loading on each of the secondary 40 MHz channel.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "obsSec80MhzUtil": { + "description": "Observable loading on each of the secondary 80 MHz channel.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "spatStreamUnderUtil": { + "description": "The percentage of time, linearly scaled with 255 representing 100 %, that the AP has underutilized spatial domain resources for given busy time of the medium.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt8" + } + }, + "required": [ + "muMimoStaCount", + "spatStreamUnderUtil", + "obsSec20MhzUtil", + "obsSec40MhzUtil", + "obsSec80MhzUtil" + ], + "type": "object", + "x-etsi-ref": "6.5.8" + }, + "timeStamp": { + "properties": { + "nanoSeconds": { + "description": "The nanoseconds part of the time. Time is defined as Unix-time since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "seconds": { + "description": "The seconds part of the time. Time is defined as Unixtime since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "required": [ + "seconds", + "nanoSeconds" + ], + "type": "object", + "x-etsi-ref": "6.5.2" + }, + "wanMetrics": { + "properties": { + "downlinkLoad": { + "description": "1-octet positive integer representing the current percentage loading of the downlink WAN connection, scaled linearly with 255 representing 100 %, as measured over an interval the duration of which is reported in Load Measurement Duration. In cases where the downlink load is unknown to the AP, the value is set to zero.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt8" + }, + "downlinkSpeed": { + "description": "4-octet positive integer whose value is an estimate of the WAN Backhaul link current downlink speed in kilobits per second.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "lmd": { + "description": "The LMD (Load Measurement Duration) field is a 2-octet positive integer representing the duration over which the Downlink Load and Uplink Load have been measured, in tenths of a second. When the actual load measurement duration is greater than the maximum value, the maximum value will be reported. The value of the LMD field is set to 0 when neither the uplink nor downlink load can be computed. When the uplink and downlink loads are computed over different intervals, the maximum interval is reported.", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint16" + }, + "uplinkLoad": { + "description": "1-octet positive integer representing the current percentage loading of the uplink WAN connection, scaled linearly with 255 representing 100 %, as measured over an interval, the duration of which is reported in Load Measurement Duration. In cases where the uplink load is unknown to the AP, the value is set to zero.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "uplinkSpeed": { + "description": "4-octet positive integer whose value is an estimate of the WAN Backhaul link's current uplink speed in kilobits per second.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt32" + }, + "wanInfo": { + "description": "Info about WAN link status, link symmetricity and capacity currently used.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + } + }, + "required": [ + "wanInfo", + "downlinkSpeed", + "uplinkSpeed", + "downlinkLoad", + "uplinkLoad", + "lmd" + ], + "type": "object", + "x-etsi-ref": "6.5.6" + }, + "wlanCap": { + "properties": { + "dmg": { + "properties": { + "ExtScMcsCap": { + "description": "Extended SC MCS capabilities as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dmgApOrPcpCapInfo": { + "description": "DMG AP or PCP capabilities information as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint16" + }, + "dmgStaBeamTrackTimeLimit": { + "description": "DMG station beam tracking time limit as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint16" + }, + "dmgStaCapInfo": { + "description": "DMG station capabilities information as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "int64", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint64" + }, + "maxNrBasicAmsduSubframes": { + "description": "Number of basic A-MSDU subframes in A-MSDU as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "maxNrShortAmsduSubframes": { + "description": "Number of short A-MSDU subframes in A-MSDU as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "sarCap": { + "description": "SAR capabilities as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "tddCap": { + "description": "TDD capabilities as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint16" + } + }, + "required": [ + "dmgStaCapInfo", + "dmgApOrPcpCapInfo", + "dmgStaBeamTrackTimeLimit", + "ExtScMcsCap", + "maxNrBasicAmsduSubframes", + "maxNrShortAmsduSubframes", + "tddCap", + "sarCap" + ], + "type": "object", + "x-etsi-ref": "6.5.17" + }, + "edmg": { + "properties": { + "ampduParameters": { + "description": "A-MPDU parameters as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "reserved": { + "description": "", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "supportedMcs": { + "description": "Supported MCS as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "trnParameters": { + "description": "Training parameters as defined in draft IEEE P802.11/D4.0 [i.11]", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint16" + } + }, + "required": [ + "ampduParameters", + "trnParameters", + "supportedMcs" + ], + "type": "object", + "x-etsi-ref": "6.5.18" + }, + "he": { + "properties": { + "heMacCapInfo": { + "description": "MAC capabilities of an Access Point.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "hePhyCapinfo": { + "description": "PHY capabilities of an Access Point.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + }, + "ppeThresholds": { + "description": "PPE Threshold determines the nominal packet padding value for a HE PPDU.", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "not defined" + }, + "supportedHeMcsNssSet": { + "description": "Supported MCS and NSS Set.", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + } + }, + "required": [ + "heMacCapInfo", + "hePhyCapinfo", + "supportedHeMcsNssSet" + ], + "type": "object", + "x-etsi-ref": "6.5.16" + }, + "ht": { + "properties": { + "ampduParameters": { + "description": "A-MPDU parameters as defined in IEEE 802.11-2016 [8].", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt8" + }, + "aselCap": { + "description": "ASEL capabilities as defined in IEEE 802.11-2016 [8].", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt8" + }, + "htCapabilityInfo": { + "description": "HT Capability Information as defined in IEEE 802.11-2016 [8].", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt16" + }, + "htExtendedCap": { + "description": "Extended HT Capabilities as defined in IEEE 802.11-2016 [8].", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt16" + }, + "supportedMcsSet": { + "description": "Supported MCS set as defined in IEEE 802.11-2016 [8].", + "format": "uint128", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint128" + }, + "txBeamFormCap": { + "description": "Transmit Beamforming Capabilities as defined in IEEE 802.11-2016 [8].", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt32" + } + }, + "required": [ + "htCapabilityInfo", + "ampduParameters", + "supportedMcsSet", + "htExtendedCap", + "txBeamFormCap", + "aselCap" + ], + "type": "object", + "x-etsi-ref": "6.5.14" + }, + "vht": { + "properties": { + "vhtCapInfo": { + "description": "VHT capabilities Info as defined in IEEE 802.11-2016 [8].", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt32" + }, + "vhtMcsNss": { + "description": "Supported VHT-MCS and NSS Set as defined in IEEE 802.11-2016 [8].", + "format": "int64", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt64" + } + }, + "required": [ + "vhtCapInfo", + "vhtMcsNss" + ], + "type": "object", + "x-etsi-ref": "6.5.15" + } + }, + "type": "object", + "x-etsi-ref": "6.5.4" + } + }, + "required": [ + "apId" + ], + "type": "object", + "x-etsi-ref": "6.2.2" +} +} \ No newline at end of file diff --git a/MEC028/WAI/AP_INFO/schemas/ProblemDetails.schema.json b/MEC028/WAI/AP_INFO/schemas/ProblemDetails.schema.json new file mode 100644 index 0000000..af823da --- /dev/null +++ b/MEC028/WAI/AP_INFO/schemas/ProblemDetails.schema.json @@ -0,0 +1,40 @@ +{ + "ProblemDetails": { + "properties": { + "detail": { + "description": "A human-readable explanation specific to this occurrence of the problem", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "instance": { + "description": "A URI reference that identifies the specific occurrence of the problem", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "URI" + }, + "status": { + "description": "The HTTP status code for this occurrence of the problem", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "title": { + "description": "A short, human-readable summary of the problem type", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "type": { + "description": "A URI reference according to IETF RFC 3986 that identifies the problem type", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "URI" + } + }, + "type": "object" + } +} \ No newline at end of file diff --git a/MEC028/WAI/EXT_SUB/ExistingSubscription.robot b/MEC028/WAI/EXT_SUB/ExistingSubscription.robot new file mode 100644 index 0000000..f6b1123 --- /dev/null +++ b/MEC028/WAI/EXT_SUB/ExistingSubscription.robot @@ -0,0 +1,120 @@ +''[Documentation] robot --outputdir ../../outputs ./ExistingSubscription.robot +... Test Suite to validate WLAN Information API (EXT_SUB) operations. + +*** Settings *** +Resource environment/variables.txt +Resource ../../../pics.txt +Resource ../../../GenericKeywords.robot +Library String +Library OperatingSystem +Library REST ${MEC-APP_SCHEMA}://${MEC-APP_HOST}:${MEC-APP_PORT} ssl_verify=false + +#GET +*** Test Cases *** +TP_MEC_MEC028_SRV_WAI_008_OK + [Documentation] + ... Check that the IUT responds with the list of Subscription" + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.6.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve existing subscription information ${SUB_ID} + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is AssocStaSubscription + Should Be Equal As Strings ${response['body']['subscriptionType']} ${SUB_TYPE} + Should Be Equal As Strings ${response['body']['callbackReference']} ${CALLBACK_URI} + Should Be Equal As Strings ${response['body']['apId']['macId']} ${MAC_ID} + +TP_MEC_MEC028_SRV_WAI_008_NF + [Documentation] + ... Check that the IUT responds with an error when a request for existing subscription with incorrect parameters is sent" + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.6.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve existing subscription information ${NOT_EXISTING_SUB_ID} + Check HTTP Response Status Code Is 404 + + +#PUT +*** Test Cases *** +TP_MEC_MEC028_SRV_WAI_009_OK + [Documentation] + ... Check that the IUT responds with a Notification Subscription when it is modified" + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.6.3.2 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Modify existing subscription information ${SUB_ID} UpdateAssocStaSubscription.json + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is AssocStaSubscription + Should Be Equal As Strings ${response['body']['subscriptionType']} ${SUB_TYPE} + Should Be Equal As Strings ${response['body']['callbackReference']} ${NEW_CALLBACK_URI} + Should Be Equal As Strings ${response['body']['apId']['macId']} ${MAC_ID} + +TP_MEC_MEC028_SRV_WAI_009_BR + [Documentation] + ... Check that the IUT responds with an error when an invalid field is set in the subscription modification request" + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.6.3.2 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Modify existing subscription information ${SUB_ID} UpdateAssocStaSubscription_BR.json + Check HTTP Response Status Code Is 400 + +#DELETE +TP_MEC_MEC028_SRV_WAI_010_OK + [Documentation] + ... Check that the IUT responds with 204 when an existing subscription is correctly deleted" + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.6.3.5 + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Remove existing subscription information ${SUB_ID} + Check HTTP Response Status Code Is 204 + +TP_MEC_MEC028_SRV_WAI_010_NF + [Documentation] + ... Check that the IUT responds with an error when an not existing subscription cannot be deleted" + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.6.3.5 + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Remove existing subscription information ${NOT_EXISTING_SUB_ID} + Check HTTP Response Status Code Is 404 + +*** Keywords *** +Retrieve existing subscription information + [Arguments] ${SUB_ID} + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${SUB_ID} + ${output}= Output response + Set Suite Variable ${response} ${output} + + +Modify existing subscription information + [Arguments] ${SUB_ID} ${content} + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + ${path} Catenate SEPARATOR= jsons/ ${content} + ${body} Get File ${path} + PUT ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${SUB_ID} ${body} + ${output}= Output response + Set Suite Variable ${response} ${output} + + +Remove existing subscription information + [Arguments] ${SUB_ID} + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + DELETE ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${SUB_ID} + ${output}= Output response + Set Suite Variable ${response} ${output} \ No newline at end of file diff --git a/MEC028/WAI/EXT_SUB/environment/variables.txt b/MEC028/WAI/EXT_SUB/environment/variables.txt new file mode 100644 index 0000000..8e5fb83 --- /dev/null +++ b/MEC028/WAI/EXT_SUB/environment/variables.txt @@ -0,0 +1,17 @@ +*** Variables *** +${apiRoot} +${apiName} wai +${apiVersion} v1 + +${MEC-APP_SCHEMA} http +${MEC-APP_HOST} 127.0.0.1 +${MEC-APP_PORT} 8082 + +${TOKEN} Basic YWxhZGRpbjpvcGVuc2VzYW1l + +${SUB_TYPE} AssocStaSubscription +${SUB_ID} 1 +${NOT_EXISTING_SUB_ID} 99 +${CALLBACK_URI} http://callback.uri/1 +${NEW_CALLBACK_URI} http://new.callback.uri/1 +${MAC_ID} macId01 \ No newline at end of file diff --git a/MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription.json b/MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription.json new file mode 100644 index 0000000..578d8f0 --- /dev/null +++ b/MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription.json @@ -0,0 +1,11 @@ +{ + "_links":{ + "href":"" + }, + + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://new.callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} \ No newline at end of file diff --git a/MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription_BR.json b/MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription_BR.json new file mode 100644 index 0000000..d5fb273 --- /dev/null +++ b/MEC028/WAI/EXT_SUB/jsons/UpdateAssocStaSubscription_BR.json @@ -0,0 +1,11 @@ +{ + "_links":{ + "href":"" + }, + + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "INVALID_VALUE" +} \ No newline at end of file diff --git a/MEC028/WAI/EXT_SUB/schemas/AssocStaSubscription.schema.json b/MEC028/WAI/EXT_SUB/schemas/AssocStaSubscription.schema.json new file mode 100644 index 0000000..956773c --- /dev/null +++ b/MEC028/WAI/EXT_SUB/schemas/AssocStaSubscription.schema.json @@ -0,0 +1,109 @@ +{ + "properties": { + "_links": { + "description": "Hyperlink related to the resource. This shall be only included in the HTTP responses and in HTTP PUT requests.", + "properties": { + "self": { + "properties": { + "href": { + "description": "URI referring to a resource", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "href" + ], + "type": "object", + "x-etsi-ref": "6.5.23" + } + }, + "required": [ + "self" + ], + "type": "object", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Structure (inlined)" + }, + "apId": { + "properties": { + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the Access Point.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique Identifier assigned to an Access Point (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks including Basic Service Set and Extended Service Set.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.3" + }, + "callbackReference": { + "description": "URI selected by the service consumer to receive notifications on the subscribed WLAN information. This shall be included both in the request and in response.", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "URI" + }, + "expiryDeadline": { + "properties": { + "nanoSeconds": { + "description": "The nanoseconds part of the time. Time is defined as Unix-time since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "seconds": { + "description": "The seconds part of the time. Time is defined as Unixtime since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "required": [ + "seconds", + "nanoSeconds" + ], + "type": "object", + "x-etsi-ref": "6.5.2" + }, + "subscriptionType": { + "description": "Shall be set to \"AssocStaSubscription\".", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "subscriptionType", + "callbackReference", + "apId" + ], + "type": "object", + "x-etsi-ref": "6.3.2" +} \ No newline at end of file diff --git a/MEC028/WAI/STA_INFO/WaiStaInfo.robot b/MEC028/WAI/STA_INFO/WaiStaInfo.robot new file mode 100644 index 0000000..0968d7d --- /dev/null +++ b/MEC028/WAI/STA_INFO/WaiStaInfo.robot @@ -0,0 +1,81 @@ +''[Documentation] robot --outputdir ../../outputs ./WaiSTAInfo.robot +... Test Suite to validate WLAN Information API (STA_INFO) operations. + +*** Settings *** +Resource environment/variables.txt +Resource ../../../pics.txt +Resource ../../../GenericKeywords.robot +Library String +Library OperatingSystem +Library REST ${MEC-APP_SCHEMA}://${MEC-APP_HOST}:${MEC-APP_PORT} ssl_verify=false + + +*** Test Cases *** +TP_MEC_MEC028_SRV_WAI_003_OK + [Documentation] + ... Check that the IUT responds with the list of Station Point + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.4.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schema/StaInfo + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the station information + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is StaInfo + ## Post condition + FOR ${staInfo} IN @{response['body']} + ${passed} Run Keyword And Return Status Should Be Equal As Strings ${staInfo['staId']['macId']} ${MAC_ID} + Exit For Loop If ${passed} + END + Should Be True ${passed} + +TP_MEC_MEC028_SRV_WAI_004_OK + [Documentation] + ... Check that the IUT responds with the list of Station Point filtered by the macId provided as query parameter + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.4.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schema/StaInfo + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the station information using filters ${filter} + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is StaInfo + ## Post condition + FOR ${staInfo} IN @{response['body']} + ${passed} Run Keyword And Return Status Should Be Equal As Strings ${staInfo['staId']['macId']} ${MAC_ID} + Exit For Loop If ${passed} + END + Should Be True ${passed} + + +TP_MEC_MEC028_SRV_WAI_004_BR + [Documentation] + ... Check that the IUT responds with an error when a request with incorrect parameters is sent by a MEC Application + ... ETSI GS MEC 028 2.1.1, clause 7.4.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schema/StaInfo + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the station information using filters ${bad_filter} + Check HTTP Response Status Code Is 400 + Check HTTP Response Body Json Schema Is ProblemDetails + + +*** Keywords *** +Retrieve the station information + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + GET ${apiRoot}/${apiName}/${apiVersion}/queries/sta/sta_information + ${output}= Output response + Set Suite Variable ${response} ${output} + +Retrieve the station information using filters + [Arguments] ${filter} + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + GET ${apiRoot}/${apiName}/${apiVersion}/queries/sta/sta_information?filter=${filter} + ${output}= Output response + Set Suite Variable ${response} ${output} \ No newline at end of file diff --git a/MEC028/WAI/STA_INFO/environment/variables.txt b/MEC028/WAI/STA_INFO/environment/variables.txt new file mode 100644 index 0000000..c64df1b --- /dev/null +++ b/MEC028/WAI/STA_INFO/environment/variables.txt @@ -0,0 +1,14 @@ +*** Variables *** +${apiRoot} +${apiName} wai +${apiVersion} v1 + +${MEC-APP_SCHEMA} http +${MEC-APP_HOST} 127.0.0.1 +${MEC-APP_PORT} 8082 + +${TOKEN} Basic YWxhZGRpbjpvcGVuc2VzYW1l + +${MAC_ID} macId01 +${filter} (eq,staId/macId,macId01) +${bad_filter} (eq,staId/mac,macId01) \ No newline at end of file diff --git a/MEC028/WAI/STA_INFO/schemas/ProblemDetails.schema.json b/MEC028/WAI/STA_INFO/schemas/ProblemDetails.schema.json new file mode 100644 index 0000000..e14c086 --- /dev/null +++ b/MEC028/WAI/STA_INFO/schemas/ProblemDetails.schema.json @@ -0,0 +1,38 @@ +{ + "properties": { + "detail": { + "description": "A human-readable explanation specific to this occurrence of the problem", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "instance": { + "description": "A URI reference that identifies the specific occurrence of the problem", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "URI" + }, + "status": { + "description": "The HTTP status code for this occurrence of the problem", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "title": { + "description": "A short, human-readable summary of the problem type", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "type": { + "description": "A URI reference according to IETF RFC 3986 that identifies the problem type", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "URI" + } + }, + "type": "object" +} \ No newline at end of file diff --git a/MEC028/WAI/STA_INFO/schemas/StaInfo.schema.json b/MEC028/WAI/STA_INFO/schemas/StaInfo.schema.json new file mode 100644 index 0000000..cc1136c --- /dev/null +++ b/MEC028/WAI/STA_INFO/schemas/StaInfo.schema.json @@ -0,0 +1,789 @@ +{ +"items":{ + "properties": { + "apAssociated": { + "properties": { + "assocId": { + "description": "Unique number which identifies a particular association between the station and Access Point.", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "string" + }, + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the Access Point.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "string" + }, + "macId": { + "description": "Unique identifier assigned to the Access Point (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "string" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.12" + }, + "beaconReport": { + "properties": { + "bssId": { + "description": "The BSSID field indicates the BSSID of the BSS(s) for which a beacon report has been received.", + "items": { + "type": "string" + }, + "minItems": 1, + "type": "array", + "x-etsi-mec-cardinality": "1..N", + "x-etsi-mec-origin-type": "String" + }, + "channelId": { + "description": "Channel number where the beacon was received.", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Integer" + }, + "measurementId": { + "description": "Measurement ID of the Measurement configuration applied to this Beacon Report.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "reportingCondition": { + "description": "As in table T9-89 of IEEE 802.11-2012 [8].", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Integer" + }, + "ssId": { + "description": "(Optional) The SSID subelement indicates the ESS(s) or IBSS(s) for which a beacon report is received.", + "items": { + "type": "string" + }, + "minItems": 1, + "type": "array", + "x-etsi-mec-cardinality": "1..N", + "x-etsi-mec-origin-type": "String" + }, + "staId": { + "properties": { + "aid": { + "description": "Number which identifies a particular association between a station and an Access Point ", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the station.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique identifier assigned to station (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.11" + } + }, + "required": [ + "staId", + "measurementId", + "channelId", + "bssId", + "ssId", + "reportingCondition" + ], + "type": "object", + "x-etsi-ref": "6.5.27" + }, + "channel": { + "description": "Channel currently used by the station.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "rssi": { + "properties": { + "rssi": { + "description": "The Received Signal Strength Indicator from a station", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint8" + } + }, + "required": [ + "rssi" + ], + "type": "object", + "x-etsi-ref": "6.5.21" + }, + "staDataRate": { + "properties": { + "staId": { + "properties": { + "aid": { + "description": "Number which identifies a particular association between a station and an Access Point ", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the station.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique identifier assigned to station (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.11" + }, + "staLastDataDownlinkRate": { + "description": "The data transmit rate in kbps that was most recently used for transmission of data PPDUs from the access point to the station.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "staLastDataUplinkRate": { + "description": "The data transmit rate in Kbps that was most recently used for transmission of data PPDUs from the associated station to the access point.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "type": "object", + "x-etsi-ref": "6.5.22" + }, + "staId": { + "properties": { + "aid": { + "description": "Number which identifies a particular association between a station and an Access Point ", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the station.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique identifier assigned to station (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.11" + }, + "staStatistics": { + "properties": { + "groupIdentity": { + "description": "Indicates the requested statistics group describing the Statistics Group Data according to table 9-114 of IEEE 802.11-2016 [8].", + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt8" + }, + "md": { + "description": "Measurement Duration.", + "format": "uint16", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "UInt16" + }, + "statisticsGroupData": { + "description": "Statistics Group Data as defined in Annex C of IEEE 802.112016 [8].", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "not specified", + "properties": { + "dot11AMPDUDelimiterCRCErrorCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11AMPDUReceivedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11AMSDUAckFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11AckFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11BeamformingFrameCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11ChannelWidthSwitchCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11DualCTSFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11DualCTSSuccessCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11ExplicitBARFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11FCSErrorCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11FailedAMSDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11FailedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11FortyMHzFrameReceivedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11FortyMHzFrameTransmittedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11FrameDuplicateCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11GrantedRDGUnusedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11GrantedRDGUsedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11GroupReceivedFrameCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11GroupTransmittedFrameCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11ImplicitBARFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11MPDUInReceivedAMPDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11MultipleRetryAMSDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11MultipleRetryCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11PSMPUTTGrantDuration": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11PSMPUTTUsedDuration": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosAckFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosDiscardedFrameCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosFailedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosFrameDuplicateCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosMPDUsReceivedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosMultipleRetryCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosRTSFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosRTSSuccessCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosReceivedFragmentCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosRetriesReceivedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosRetryCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosTransmittedFragmentCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11QosTransmittedFrameCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RSNAStatsBIPMICErrors": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RSNAStatsCCMPDecryptErrors": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RSNAStatsCCMPReplays": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RSNAStatsCMACReplays": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RSNAStatsRobustMgmtCCMPReplays": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RSNAStatsTKIPICVErrors": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RSNAStatsTKIPReplays": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RTSFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RTSLSIGFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RTSLSIGSuccessCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RTSSuccessCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11ReceivedAMSDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11ReceivedFragmentCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11ReceivedOctetsInAMPDUCount": { + "format": "int64", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint64" + }, + "dot11ReceivedOctetsInAMSDUCount": { + "format": "int64", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint64" + }, + "dot11RetryAMSDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11RetryCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11STAStatisticsAPAverageAccessDelay": { + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dot11STAStatisticsAverageAccessDelayBackGround": { + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dot11STAStatisticsAverageAccessDelayBestEffort": { + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dot11STAStatisticsAverageAccessDelayVideo": { + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dot11STAStatisticsAverageAccessDelayVoice": { + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dot11STAStatisticsChannelUtilization": { + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dot11STAStatisticsStationCount": { + "format": "uint8", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint8" + }, + "dot11STBCCTSFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11STBCCTSSuccessCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedAMPDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedAMSDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedFragmentCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedFrameCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedFramesInGrantedRDGCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedMPDUsInAMPDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedOctetsInAMPDUCount": { + "format": "int64", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint64" + }, + "dot11TransmittedOctetsInAMSDUCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TransmittedOctetsInGrantedRDGCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TwentyMHzFrameReceivedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11TwentyMHzFrameTransmittedCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11nonSTBCCTSFailureCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + }, + "dot11nonSTBCCTSSuccessCount": { + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "type": "object" + } + }, + "required": [ + "md", + "groupIdentity", + "statisticsGroupData" + ], + "type": "object", + "x-etsi-ref": "6.5.13" + }, + "timeStamp": { + "properties": { + "nanoSeconds": { + "description": "The nanoseconds part of the time. Time is defined as Unix-time since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "seconds": { + "description": "The seconds part of the time. Time is defined as Unixtime since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "required": [ + "seconds", + "nanoSeconds" + ], + "type": "object", + "x-etsi-ref": "6.5.2" + } + }, + "required": [ + "staId" + ], + "type": "object", + "x-etsi-ref": "6.2.3" + } +} \ No newline at end of file diff --git a/MEC028/WAI/SUB/WaiSubscription.robot b/MEC028/WAI/SUB/WaiSubscription.robot new file mode 100644 index 0000000..941eaf0 --- /dev/null +++ b/MEC028/WAI/SUB/WaiSubscription.robot @@ -0,0 +1,142 @@ +''[Documentation] robot --outputdir ../../outputs ./WaiSubscription.robot +... Test Suite to validate WLAN Information API (SUB) operations. + +*** Settings *** +Resource environment/variables.txt +Resource ../../../pics.txt +Resource ../../../GenericKeywords.robot +Library String +Library OperatingSystem +Library REST ${MEC-APP_SCHEMA}://${MEC-APP_HOST}:${MEC-APP_PORT} ssl_verify=false + +#POST +*** Test Cases *** +TP_MEC_MEC028_SRV_WAI_007_OK + [Documentation] + ... Check that the IUT responds with a Notification Subscription + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.4 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Send a request for creating a subscription AssocStaSubscription.json + Check HTTP Response Status Code Is 201 + Check HTTP Response Body Json Schema Is AssocStaSubscription + Should Be Equal As Strings ${response['body']['subscriptionType']} ${SUB_TYPE} + Should Be Equal As Strings ${response['body']['_links']['self']['href']} ${HREF} + Should Be Equal As Strings ${response['headers']['Location']} ${HREF} + +TP_MEC_MEC028_SRV_WAI_007_BR + [Documentation] + ... Check that the IUT responds with an error when an invalid Subscription request is sent + ... ETSI GS MEC 028 2.1.1, clause 7.5.3.4 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Send a request for creating a subscription AssocStaSubscription_BR.json + Check HTTP Response Status Code Is 400 + +TP_MEC_MEC028_SRV_WAI_007_NF + [Documentation] + ... Check that the IUT responds with an error when a request with not existing parameters is sent + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Send a request for creating a subscription using wrong endpoint AssocStaSubscription.json + Check HTTP Response Status Code Is 404 + + +#GET +TP_MEC_MEC028_SRV_WAI_005_OK + [Documentation] + ... Check that the IUT responds with the requested list of subscription + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the subscription information ${SUB_FILTER} + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is SubscriptionLinkList + FOR ${assocStaSub} IN @{response['body']['assocStaSubscription']} + ${passed} Run Keyword And Return Status Should Be Equal As Strings ${assocStaSub['_links']['self']['href']} ${HREF} + Exit For Loop If ${passed} + END + +TP_MEC_MEC028_SRV_WAI_006_OK + [Documentation] + ... Check that the IUT responds with the requested list of subscription + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the subscription information ${SUB_FILTER} + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is SubscriptionLinkList + Should Be Equal As Strings ${response['body']['_links']['self']['href']} ${HREF} + +TP_MEC_MEC028_SRV_WAI_006_BR + [Documentation] + ... Check that the IUT responds with the requested list of subscription + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + Retrieve the subscription information ${INVALID_SUB_FILTER} + Check HTTP Response Status Code Is 400 + +TP_MEC_MEC028_SRV_WAI_006_NF + [Documentation] + ... Check that the IUT responds with an error when a request with not existing parameters is sent + ... Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 + ... https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + Retrieve the subscription information using wrong endpoint + Check HTTP Response Status Code Is 404 + +*** Keywords *** +Send a request for creating a subscription + [Arguments] ${content} + Log Creating a new subscription + #Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + ${path} Catenate SEPARATOR= jsons/ ${content} + ${body} Get File ${path} + Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} + Log ${body} + ${output}= Output response + Set Suite Variable ${response} ${output} + +Send a request for creating a subscription using wrong endpoint + [Arguments] ${content} + Log Creating a new subscription + #Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + ${path} Catenate SEPARATOR= jsons/ ${content} + ${body} Get File ${path} + Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions_INVALID_URI ${body} + ${output}= Output response + Set Suite Variable ${response} ${output} + +Retrieve the subscription information + [Arguments] ${subscription_type} + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + #Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?subscription_type=${subscription_type} + ${output}= Output response + Set Suite Variable ${response} ${output} + +Retrieve the subscription information using wrong endpoint + Should Be True ${PIC_MEC_SYSTEM} == 1 + Should Be True ${PIC_SERVICES} == 1 + #Set Headers {"Accept":"application/json"} + Set Headers {"Content-Type":"application/json"} + Set Headers {"Authorization":"${TOKEN}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions_INVALID_URI + ${output}= Output response + Set Suite Variable ${response} ${output} \ No newline at end of file diff --git a/MEC028/WAI/SUB/environment/variables.txt b/MEC028/WAI/SUB/environment/variables.txt new file mode 100644 index 0000000..dfa2d41 --- /dev/null +++ b/MEC028/WAI/SUB/environment/variables.txt @@ -0,0 +1,18 @@ +*** Variables *** +${apiRoot} +${apiName} wai +${apiVersion} v1 + +${MEC-APP_SCHEMA} http +${MEC-APP_HOST} 127.0.0.1 +${MEC-APP_PORT} 8082 + +${TOKEN} Basic YWxhZGRpbjpvcGVuc2VzYW1l + +${SUB_TYPE} AssocStaSubscription + +${SUB_FILTER} assoc_sta +${INVALID_SUB_FILTER} assocStaSub + +${HREF} /wai/v1/subscriptions/1 +${CALLBACK_URI} http://callback.uri/1 \ No newline at end of file diff --git a/MEC028/WAI/SUB/jsons/AssocStaSubscription.json b/MEC028/WAI/SUB/jsons/AssocStaSubscription.json new file mode 100644 index 0000000..152ca49 --- /dev/null +++ b/MEC028/WAI/SUB/jsons/AssocStaSubscription.json @@ -0,0 +1,7 @@ +{ + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} \ No newline at end of file diff --git a/MEC028/WAI/SUB/jsons/AssocStaSubscription_BR.json b/MEC028/WAI/SUB/jsons/AssocStaSubscription_BR.json new file mode 100644 index 0000000..d5fb273 --- /dev/null +++ b/MEC028/WAI/SUB/jsons/AssocStaSubscription_BR.json @@ -0,0 +1,11 @@ +{ + "_links":{ + "href":"" + }, + + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "INVALID_VALUE" +} \ No newline at end of file diff --git a/MEC028/WAI/SUB/schemas/AssocStaSubscription.schema.json b/MEC028/WAI/SUB/schemas/AssocStaSubscription.schema.json new file mode 100644 index 0000000..956773c --- /dev/null +++ b/MEC028/WAI/SUB/schemas/AssocStaSubscription.schema.json @@ -0,0 +1,109 @@ +{ + "properties": { + "_links": { + "description": "Hyperlink related to the resource. This shall be only included in the HTTP responses and in HTTP PUT requests.", + "properties": { + "self": { + "properties": { + "href": { + "description": "URI referring to a resource", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "href" + ], + "type": "object", + "x-etsi-ref": "6.5.23" + } + }, + "required": [ + "self" + ], + "type": "object", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Structure (inlined)" + }, + "apId": { + "properties": { + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the Access Point.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique Identifier assigned to an Access Point (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks including Basic Service Set and Extended Service Set.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.3" + }, + "callbackReference": { + "description": "URI selected by the service consumer to receive notifications on the subscribed WLAN information. This shall be included both in the request and in response.", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "URI" + }, + "expiryDeadline": { + "properties": { + "nanoSeconds": { + "description": "The nanoseconds part of the time. Time is defined as Unix-time since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "seconds": { + "description": "The seconds part of the time. Time is defined as Unixtime since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "required": [ + "seconds", + "nanoSeconds" + ], + "type": "object", + "x-etsi-ref": "6.5.2" + }, + "subscriptionType": { + "description": "Shall be set to \"AssocStaSubscription\".", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "subscriptionType", + "callbackReference", + "apId" + ], + "type": "object", + "x-etsi-ref": "6.3.2" +} \ No newline at end of file diff --git a/MEC028/WAI/SUB/schemas/SubscriptionLinkList.schema.json b/MEC028/WAI/SUB/schemas/SubscriptionLinkList.schema.json new file mode 100644 index 0000000..b4818c1 --- /dev/null +++ b/MEC028/WAI/SUB/schemas/SubscriptionLinkList.schema.json @@ -0,0 +1,272 @@ +{ + "properties": { + "_links": { + "description": "Hyperlink related to the resource. This shall be only included in the HTTP responses and in HTTP PUT requests.", + "properties": { + "self": { + "properties": { + "href": { + "description": "URI referring to a resource", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "href" + ], + "type": "object", + "x-etsi-ref": "6.5.23" + } + }, + "type": "object", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Structure (inlined)" + }, + "assocStaSubscription": { + "items": { + "properties": { + "_links": { + "description": "Hyperlink related to the resource. This shall be only included in the HTTP responses and in HTTP PUT requests.", + "properties": { + "self": { + "properties": { + "href": { + "description": "URI referring to a resource", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "href" + ], + "type": "object", + "x-etsi-ref": "6.5.23" + } + }, + "required": [ + "self" + ], + "type": "object", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Structure (inlined)" + }, + "apId": { + "properties": { + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the Access Point.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique Identifier assigned to an Access Point (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks including Basic Service Set and Extended Service Set.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.3" + }, + "callbackReference": { + "description": "URI selected by the service consumer to receive notifications on the subscribed WLAN information. This shall be included both in the request and in response.", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "URI" + }, + "expiryDeadline": { + "properties": { + "nanoSeconds": { + "description": "The nanoseconds part of the time. Time is defined as Unix-time since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "seconds": { + "description": "The seconds part of the time. Time is defined as Unixtime since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "required": [ + "seconds", + "nanoSeconds" + ], + "type": "object", + "x-etsi-ref": "6.5.2" + }, + "subscriptionType": { + "description": "Shall be set to \"AssocStaSubscription\".", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "subscriptionType", + "callbackReference", + "apId" + ], + "type": "object", + "x-etsi-ref": "6.3.2" + }, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "AssocStaSubscription" + }, + "staDataRateSubscription": { + "items": { + "properties": { + "_links": { + "description": "Hyperlink related to the resource. This shall be only included in the HTTP responses and in HTTP PUT requests.", + "properties": { + "self": { + "properties": { + "href": { + "description": "URI referring to a resource", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "href" + ], + "type": "object", + "x-etsi-ref": "6.5.23" + } + }, + "required": [ + "self" + ], + "type": "object", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "Structure (inlined)" + }, + "callbackReference": { + "description": "URI selected by the service consumer to receive notifications on the subscribed WLAN Access Information Service. This shall be included both in the request and in response.", + "format": "uri", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "URI" + }, + "expiryDeadline": { + "properties": { + "nanoSeconds": { + "description": "The nanoseconds part of the time. Time is defined as Unix-time since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + }, + "seconds": { + "description": "The seconds part of the time. Time is defined as Unixtime since January 1, 1970, 00:00:00 UTC.", + "format": "uint32", + "type": "integer", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "Uint32" + } + }, + "required": [ + "seconds", + "nanoSeconds" + ], + "type": "object", + "x-etsi-ref": "6.5.2" + }, + "staId": { + "description": "Identifier(s) to uniquely specify the target client station(s) for the subscription", + "items": { + "properties": { + "aid": { + "description": "Number which identifies a particular association between a station and an Access Point ", + "type": "string", + "x-etsi-mec-cardinality": "0..1", + "x-etsi-mec-origin-type": "String" + }, + "ipAddress": { + "description": "IPv4 or IPv6 address allocated for the station.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + }, + "macId": { + "description": "Unique identifier assigned to station (as network interface controller) for communications at the data link layer of a network segment.", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + }, + "ssid": { + "description": "Service Set Identifier to identify logical networks.", + "items": { + "type": "string" + }, + "minItems": 0, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "macId" + ], + "type": "object", + "x-etsi-ref": "6.5.11" + }, + "minItems": 1, + "type": "array", + "x-etsi-mec-cardinality": "1..N", + "x-etsi-mec-origin-type": "StaIdentity" + }, + "subscriptionType": { + "description": "Shall be set to \"StaDataRateSubscription\".", + "type": "string", + "x-etsi-mec-cardinality": "1", + "x-etsi-mec-origin-type": "String" + } + }, + "required": [ + "subscriptionType", + "callbackReference", + "staId" + ], + "type": "object", + "x-etsi-ref": "6.3.3" + }, + "type": "array", + "x-etsi-mec-cardinality": "0..N", + "x-etsi-mec-origin-type": "StaDataRateSubscription" + } + }, + "required": [ + "_links" + ], + "type": "object" +} \ No newline at end of file diff --git a/MEC028/outputs/log-20210506-145611.html b/MEC028/outputs/log-20210506-145611.html new file mode 100644 index 0000000..5b94fad --- /dev/null +++ b/MEC028/outputs/log-20210506-145611.html @@ -0,0 +1,2189 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+

Opening Robot Framework log failed

+ +
+ + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/MEC028/outputs/log.html b/MEC028/outputs/log.html new file mode 100644 index 0000000..92a7612 --- /dev/null +++ b/MEC028/outputs/log.html @@ -0,0 +1,2189 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+

Opening Robot Framework log failed

+ +
+ + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/MEC028/outputs/output-20210506-145611.xml b/MEC028/outputs/output-20210506-145611.xml new file mode 100644 index 0000000..f889481 --- /dev/null +++ b/MEC028/outputs/output-20210506-145611.xml @@ -0,0 +1,1000 @@ + + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +AssocStaSubscription.json + +Creating a new subscription +Logs the given message with the given level. +Creating a new subscription + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${path} +SEPARATOR= +jsons/ +${content} +Catenates the given items together and returns the resulted string. +${path} = jsons/AssocStaSubscription.json + + + +${body} +${path} +Returns the contents of a specified file. +Getting file '<a href="file://C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json">C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json</a>'. +${body} = { + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions +${body} +http +*Sends a POST request to the endpoint.* + + + +${body} +Logs the given message with the given level. +{ + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.015031000000000001, + "status": 201, + "body": { + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + }, + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" + }, + "headers": { + "Content-Type": "application/json; charset=utf-8", + "Location": "/wai/v1/subscriptions/1", + "Content-Length": "222", + "Date": "Thu, 06 May 2021 12:56:11 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.015031000000000001, 'status': 201, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'apId': {'macId': 'macId01'}, 'callbackReference': 'http://callback.uri/1', 'subscrip... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.015031000000000001, 'status': 201, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'apId': {'macId': 'macId01'}, 'callbackReference': 'http://callback.uri/1', 'subscrip... + + + + + +201 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 201 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + + +AssocStaSubscription + +${response['headers']['Content-Type']} +application/json +Fails if ``container`` does not contain ``item`` one or more times. + + + +${schema} +SEPARATOR= +${input} +.schema.json +Catenates the given items together and returns the resulted string. +${schema} = AssocStaSubscription.schema.json + + + +${schema} +${response['body']} +Validates the sample JSON against the given schema. + + + +Json Schema Validation OK +Logs the given message with the given level. +Json Schema Validation OK + + + + + +${response['body']['subscriptionType']} +${SUB_TYPE} +Fails if objects are unequal after converting them to strings. + + + +${response['body']['_links']['self']['href']} +${HREF} +Fails if objects are unequal after converting them to strings. + + + +${response['headers']['Location']} +${HREF} +Fails if objects are unequal after converting them to strings. + + +Check that the IUT responds with a Notification Subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.4 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +AssocStaSubscription_BR.json + +Creating a new subscription +Logs the given message with the given level. +Creating a new subscription + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${path} +SEPARATOR= +jsons/ +${content} +Catenates the given items together and returns the resulted string. +${path} = jsons/AssocStaSubscription_BR.json + + + +${body} +${path} +Returns the contents of a specified file. +Getting file '<a href="file://C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription_BR.json">C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription_BR.json</a>'. +${body} = { + "_links":{ + "href":"" + }, + + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "INVALID_VALUE" +} + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions +${body} +http +*Sends a POST request to the endpoint.* + + + +${body} +Logs the given message with the given level. +{ + "_links":{ + "href":"" + }, + + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "INVALID_VALUE" +} + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.00544, + "status": 400, + "body": "", + "headers": { + "Content-Type": "application/problem+json; charset=utf-8", + "Content-Length": "0", + "Date": "Thu, 06 May 2021 12:56:12 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.00544, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:56:12 GMT', 'Connection': 'ke... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.00544, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:56:12 GMT', 'Connection': 'ke... + + + + + +400 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 400 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with an error when an invalid Subscription request is sent +ETSI GS MEC 028 2.1.1, clause 7.5.3.4 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +AssocStaSubscription.json + +Creating a new subscription +Logs the given message with the given level. +Creating a new subscription + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${path} +SEPARATOR= +jsons/ +${content} +Catenates the given items together and returns the resulted string. +${path} = jsons/AssocStaSubscription.json + + + +${body} +${path} +Returns the contents of a specified file. +Getting file '<a href="file://C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json">C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json</a>'. +${body} = { + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions_INVALID_URI +${body} +http +*Sends a POST request to the endpoint.* +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.0037170000000000003, + "status": 404, + "body": "<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n<meta charset=\"utf-8\">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot POST /wai/v1/subscriptions_INVALID_URI</pre>\n</body>\n</html>\n", + "headers": { + "Content-Security-Policy": "default-src 'none'", + "X-Content-Type-Options": "nosniff", + "Content-Type": "text/html; charset=utf-8", + "Content-Length": "172", + "Date": "Thu, 06 May 2021 12:56:12 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.0037170000000000003, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot POST /wai/v1/subscripti... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.0037170000000000003, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot POST /wai/v1/subscripti... + + + + + +404 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 404 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with an error when a request with not existing parameters is sent +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +${SUB_FILTER} + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions?subscription_type=${subscription_type} +http +*Sends a GET request to the endpoint.* + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.004779, + "status": 200, + "body": { + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + }, + "staDataRateSubscription": [], + "assocStaSubscription": [ + { + "subscriptionType": "AssocStaSubscription", + "callbackReference": "http://callback/uri", + "apId": { + "macId": "macId01" + }, + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + } + } + ] + }, + "headers": { + "Content-Type": "application/json; charset=utf-8", + "Content-Length": "361", + "Date": "Thu, 06 May 2021 12:56:12 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.004779, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocStaSubscriptio... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.004779, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocStaSubscriptio... + + + + + +200 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 200 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + + +SubscriptionLinkList + +${response['headers']['Content-Type']} +application/json +Fails if ``container`` does not contain ``item`` one or more times. + + + +${schema} +SEPARATOR= +${input} +.schema.json +Catenates the given items together and returns the resulted string. +${schema} = SubscriptionLinkList.schema.json + + + +${schema} +${response['body']} +Validates the sample JSON against the given schema. + + + +Json Schema Validation OK +Logs the given message with the given level. +Json Schema Validation OK + + + + + +${assocStaSub} +@{response['body']['assocStaSubscription']} + +{'subscriptionType': 'AssocStaSubscription', 'callbackReference': 'http://callback/uri', 'apId': {'macId': 'macId01'}, '_links': {'self': {'href': '/wai/v1/subscriptions/1'}}} + +${passed} +Should Be Equal As Strings +${assocStaSub['_links']['self']['href']} +${HREF} +Runs the given keyword with given arguments and returns the status as a Boolean value. + +${assocStaSub['_links']['self']['href']} +${HREF} +Fails if objects are unequal after converting them to strings. + + +${passed} = True + + + +${passed} +Stops executing the enclosing for loop if the ``condition`` is true. +Exiting for loop altogether. + + + + + + +Check that the IUT responds with the requested list of subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +${SUB_FILTER} + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions?subscription_type=${subscription_type} +http +*Sends a GET request to the endpoint.* + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.004893, + "status": 200, + "body": { + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + }, + "staDataRateSubscription": [], + "assocStaSubscription": [ + { + "subscriptionType": "AssocStaSubscription", + "callbackReference": "http://callback/uri", + "apId": { + "macId": "macId01" + }, + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + } + } + ] + }, + "headers": { + "Content-Type": "application/json; charset=utf-8", + "Content-Length": "361", + "Date": "Thu, 06 May 2021 12:56:12 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.004893, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocStaSubscriptio... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.004893, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocStaSubscriptio... + + + + + +200 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 200 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + + +SubscriptionLinkList + +${response['headers']['Content-Type']} +application/json +Fails if ``container`` does not contain ``item`` one or more times. + + + +${schema} +SEPARATOR= +${input} +.schema.json +Catenates the given items together and returns the resulted string. +${schema} = SubscriptionLinkList.schema.json + + + +${schema} +${response['body']} +Validates the sample JSON against the given schema. + + + +Json Schema Validation OK +Logs the given message with the given level. +Json Schema Validation OK + + + + + +${response['body']['_links']['self']['href']} +${HREF} +Fails if objects are unequal after converting them to strings. + + +Check that the IUT responds with the requested list of subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +${INVALID_SUB_FILTER} + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions?subscription_type=${subscription_type} +http +*Sends a GET request to the endpoint.* + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.005156, + "status": 400, + "body": "", + "headers": { + "Content-Type": "application/problem+json; charset=utf-8", + "Content-Length": "0", + "Date": "Thu, 06 May 2021 12:56:12 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.005156, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:56:12 GMT', 'Connection': 'k... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.005156, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:56:12 GMT', 'Connection': 'k... + + + + + +400 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 400 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with the requested list of subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions_INVALID_URI +http +*Sends a GET request to the endpoint.* +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.003614, + "status": 404, + "body": "<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n<meta charset=\"utf-8\">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot GET /wai/v1/subscriptions_INVALID_URI</pre>\n</body>\n</html>\n", + "headers": { + "Content-Security-Policy": "default-src 'none'", + "X-Content-Type-Options": "nosniff", + "Content-Type": "text/html; charset=utf-8", + "Content-Length": "171", + "Date": "Thu, 06 May 2021 12:56:12 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.003614, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot GET /wai/v1/subscriptions_INVALID_UR... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.003614, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot GET /wai/v1/subscriptions_INVALID_UR... + + + + + +404 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 404 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with an error when a request with not existing parameters is sent +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + + + +All Tests + + + + +WaiSubscription + + + +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 + + diff --git a/MEC028/outputs/output.xml b/MEC028/outputs/output.xml new file mode 100644 index 0000000..ef1cfcf --- /dev/null +++ b/MEC028/outputs/output.xml @@ -0,0 +1,1000 @@ + + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +AssocStaSubscription.json + +Creating a new subscription +Logs the given message with the given level. +Creating a new subscription + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${path} +SEPARATOR= +jsons/ +${content} +Catenates the given items together and returns the resulted string. +${path} = jsons/AssocStaSubscription.json + + + +${body} +${path} +Returns the contents of a specified file. +Getting file '<a href="file://C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json">C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json</a>'. +${body} = { + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions +${body} +http +*Sends a POST request to the endpoint.* + + + +${body} +Logs the given message with the given level. +{ + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.016300000000000002, + "status": 201, + "body": { + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + }, + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" + }, + "headers": { + "Content-Type": "application/json; charset=utf-8", + "Location": "/wai/v1/subscriptions/1", + "Content-Length": "222", + "Date": "Thu, 06 May 2021 12:55:53 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.016300000000000002, 'status': 201, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'apId': {'macId': 'macId01'}, 'callbackReference': 'http://callback.uri/1', 'subscrip... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.016300000000000002, 'status': 201, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'apId': {'macId': 'macId01'}, 'callbackReference': 'http://callback.uri/1', 'subscrip... + + + + + +201 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 201 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + + +AssocStaSubscription + +${response['headers']['Content-Type']} +application/json +Fails if ``container`` does not contain ``item`` one or more times. + + + +${schema} +SEPARATOR= +${input} +.schema.json +Catenates the given items together and returns the resulted string. +${schema} = AssocStaSubscription.schema.json + + + +${schema} +${response['body']} +Validates the sample JSON against the given schema. + + + +Json Schema Validation OK +Logs the given message with the given level. +Json Schema Validation OK + + + + + +${response['body']['subscriptionType']} +${SUB_TYPE} +Fails if objects are unequal after converting them to strings. + + + +${response['body']['_links']['self']['href']} +${HREF} +Fails if objects are unequal after converting them to strings. + + + +${response['headers']['Location']} +${HREF} +Fails if objects are unequal after converting them to strings. + + +Check that the IUT responds with a Notification Subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.4 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +AssocStaSubscription_BR.json + +Creating a new subscription +Logs the given message with the given level. +Creating a new subscription + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${path} +SEPARATOR= +jsons/ +${content} +Catenates the given items together and returns the resulted string. +${path} = jsons/AssocStaSubscription_BR.json + + + +${body} +${path} +Returns the contents of a specified file. +Getting file '<a href="file://C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription_BR.json">C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription_BR.json</a>'. +${body} = { + "_links":{ + "href":"" + }, + + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "INVALID_VALUE" +} + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions +${body} +http +*Sends a POST request to the endpoint.* + + + +${body} +Logs the given message with the given level. +{ + "_links":{ + "href":"" + }, + + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "INVALID_VALUE" +} + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.005856, + "status": 400, + "body": "", + "headers": { + "Content-Type": "application/problem+json; charset=utf-8", + "Content-Length": "0", + "Date": "Thu, 06 May 2021 12:55:53 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.005856, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:55:53 GMT', 'Connection': 'k... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.005856, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:55:53 GMT', 'Connection': 'k... + + + + + +400 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 400 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with an error when an invalid Subscription request is sent +ETSI GS MEC 028 2.1.1, clause 7.5.3.4 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +AssocStaSubscription.json + +Creating a new subscription +Logs the given message with the given level. +Creating a new subscription + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${path} +SEPARATOR= +jsons/ +${content} +Catenates the given items together and returns the resulted string. +${path} = jsons/AssocStaSubscription.json + + + +${body} +${path} +Returns the contents of a specified file. +Getting file '<a href="file://C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json">C:\Users\pietr\Desktop\gs032p3-robot-test-suite\MEC028\WAI\SUB\jsons\AssocStaSubscription.json</a>'. +${body} = { + "apId": { + "macId": "macId01" + }, + "callbackReference": "http://callback.uri/1", + "subscriptionType": "AssocStaSubscription" +} + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions_INVALID_URI +${body} +http +*Sends a POST request to the endpoint.* +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.0030830000000000002, + "status": 404, + "body": "<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n<meta charset=\"utf-8\">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot POST /wai/v1/subscriptions_INVALID_URI</pre>\n</body>\n</html>\n", + "headers": { + "Content-Security-Policy": "default-src 'none'", + "X-Content-Type-Options": "nosniff", + "Content-Type": "text/html; charset=utf-8", + "Content-Length": "172", + "Date": "Thu, 06 May 2021 12:55:53 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.0030830000000000002, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot POST /wai/v1/subscripti... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.0030830000000000002, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot POST /wai/v1/subscripti... + + + + + +404 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 404 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with an error when a request with not existing parameters is sent +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +${SUB_FILTER} + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions?subscription_type=${subscription_type} +http +*Sends a GET request to the endpoint.* + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.005093, + "status": 200, + "body": { + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + }, + "staDataRateSubscription": [], + "assocStaSubscription": [ + { + "subscriptionType": "AssocStaSubscription", + "callbackReference": "http://callback/uri", + "apId": { + "macId": "macId01" + }, + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + } + } + ] + }, + "headers": { + "Content-Type": "application/json; charset=utf-8", + "Content-Length": "361", + "Date": "Thu, 06 May 2021 12:55:53 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.005093, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocStaSubscriptio... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.005093, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocStaSubscriptio... + + + + + +200 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 200 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + + +SubscriptionLinkList + +${response['headers']['Content-Type']} +application/json +Fails if ``container`` does not contain ``item`` one or more times. + + + +${schema} +SEPARATOR= +${input} +.schema.json +Catenates the given items together and returns the resulted string. +${schema} = SubscriptionLinkList.schema.json + + + +${schema} +${response['body']} +Validates the sample JSON against the given schema. + + + +Json Schema Validation OK +Logs the given message with the given level. +Json Schema Validation OK + + + + + +${assocStaSub} +@{response['body']['assocStaSubscription']} + +{'subscriptionType': 'AssocStaSubscription', 'callbackReference': 'http://callback/uri', 'apId': {'macId': 'macId01'}, '_links': {'self': {'href': '/wai/v1/subscriptions/1'}}} + +${passed} +Should Be Equal As Strings +${assocStaSub['_links']['self']['href']} +${HREF} +Runs the given keyword with given arguments and returns the status as a Boolean value. + +${assocStaSub['_links']['self']['href']} +${HREF} +Fails if objects are unequal after converting them to strings. + + +${passed} = True + + + +${passed} +Stops executing the enclosing for loop if the ``condition`` is true. +Exiting for loop altogether. + + + + + + +Check that the IUT responds with the requested list of subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +${SUB_FILTER} + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions?subscription_type=${subscription_type} +http +*Sends a GET request to the endpoint.* + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.005634999999999999, + "status": 200, + "body": { + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + }, + "staDataRateSubscription": [], + "assocStaSubscription": [ + { + "subscriptionType": "AssocStaSubscription", + "callbackReference": "http://callback/uri", + "apId": { + "macId": "macId01" + }, + "_links": { + "self": { + "href": "/wai/v1/subscriptions/1" + } + } + } + ] + }, + "headers": { + "Content-Type": "application/json; charset=utf-8", + "Content-Length": "361", + "Date": "Thu, 06 May 2021 12:55:53 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.005634999999999999, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocSt... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.005634999999999999, 'status': 200, 'body': {'_links': {'self': {'href': '/wai/v1/subscriptions/1'}}, 'staDataRateSubscription': [], 'assocStaSubscription': [{'subscriptionType': 'AssocSt... + + + + + +200 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 200 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + + +SubscriptionLinkList + +${response['headers']['Content-Type']} +application/json +Fails if ``container`` does not contain ``item`` one or more times. + + + +${schema} +SEPARATOR= +${input} +.schema.json +Catenates the given items together and returns the resulted string. +${schema} = SubscriptionLinkList.schema.json + + + +${schema} +${response['body']} +Validates the sample JSON against the given schema. + + + +Json Schema Validation OK +Logs the given message with the given level. +Json Schema Validation OK + + + + + +${response['body']['_links']['self']['href']} +${HREF} +Fails if objects are unequal after converting them to strings. + + +Check that the IUT responds with the requested list of subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +${INVALID_SUB_FILTER} + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions?subscription_type=${subscription_type} +http +*Sends a GET request to the endpoint.* + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.005876999999999999, + "status": 400, + "body": "", + "headers": { + "Content-Type": "application/problem+json; charset=utf-8", + "Content-Length": "0", + "Date": "Thu, 06 May 2021 12:55:53 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.005876999999999999, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:55:53 GMT', 'Con... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.005876999999999999, 'status': 400, 'body': '', 'headers': {'Content-Type': 'application/problem+json; charset=utf-8', 'Content-Length': '0', 'Date': 'Thu, 06 May 2021 12:55:53 GMT', 'Con... + + + + + +400 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 400 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with the requested list of subscription +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + + +${PIC_MEC_SYSTEM} == 1 +Fails if the given condition is not true. + + + +${PIC_SERVICES} == 1 +Fails if the given condition is not true. + + + +{"Content-Type":"application/json"} +settings +*Sets new request headers or updates the existing.* + + + +{"Authorization":"${TOKEN}"} +settings +*Sets new request headers or updates the existing.* + + + +${apiRoot}/${apiName}/${apiVersion}/subscriptions_INVALID_URI +http +*Sends a GET request to the endpoint.* +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 + + + +${output} +response +I/O +*Outputs JSON to terminal or a file.* + +{ + "seconds": 0.0049169999999999995, + "status": 404, + "body": "<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n<meta charset=\"utf-8\">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot GET /wai/v1/subscriptions_INVALID_URI</pre>\n</body>\n</html>\n", + "headers": { + "Content-Security-Policy": "default-src 'none'", + "X-Content-Type-Options": "nosniff", + "Content-Type": "text/html; charset=utf-8", + "Content-Length": "171", + "Date": "Thu, 06 May 2021 12:55:53 GMT", + "Connection": "keep-alive", + "Keep-Alive": "timeout=5" + } +} +${output} = {'seconds': 0.0049169999999999995, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot GET /wai/v1/subscriptio... + + + +${response} +${output} +Makes a variable available everywhere within the scope of the current suite. +${response} = {'seconds': 0.0049169999999999995, 'status': 404, 'body': '<!DOCTYPE html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<title>Error</title>\n</head>\n<body>\n<pre>Cannot GET /wai/v1/subscriptio... + + + + + +404 + +${status} +${expected_status} +Converts the given item to an integer number. +${status} = 404 + + + +${response['status']} +${status} +Fails if the given objects are unequal. + + + +Status code validated +Logs the given message with the given level. +Status code validated + + + + +Check that the IUT responds with an error when a request with not existing parameters is sent +Reference "ETSI GS MEC 028 2.1.1, clause 7.5.3.1 +https://forge.etsi.org/rep/mec/gs028-wai-api/blob/v2.1.1/WlanInformationApi.yaml#/schemas/AssocStaSubscription + + + + + + +All Tests + + + + +WaiSubscription + + + +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 +Response body content is not JSON. Content-Type is: text/html; charset=utf-8 + + diff --git a/MEC028/outputs/report-20210506-145611.html b/MEC028/outputs/report-20210506-145611.html new file mode 100644 index 0000000..e75ee9b --- /dev/null +++ b/MEC028/outputs/report-20210506-145611.html @@ -0,0 +1,2458 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+

Opening Robot Framework report failed

+ +
+ + + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/MEC028/outputs/report.html b/MEC028/outputs/report.html new file mode 100644 index 0000000..747624b --- /dev/null +++ b/MEC028/outputs/report.html @@ -0,0 +1,2458 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+

Opening Robot Framework report failed

+ +
+ + + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- GitLab