Commit d2c7ac5c authored by Yann Garcia's avatar Yann Garcia
Browse files

Review TPs for MEC015

parent 76841d29
Loading
Loading
Loading
Loading
+494 −68

File changed.

Preview size limit exceeded, changes collapsed.

+6 −117
Original line number Diff line number Diff line
@@ -38,8 +38,7 @@ Package MEC_MEC015_SRV_TM {

      Initial conditions  with {
         the IUT entity being_in idle_state and
         the MEC_APP entity having a bwInfo containing
            appInsId indicating value APP_INSTANCE_ID
         the MEC_APP entity having a oneOrmore bwInfo
         ;
      }

@@ -250,7 +249,7 @@ Package MEC_MEC015_SRV_TM {
               // MEC 015 Clause 8.4.3.4
               the IUT entity sends a HTTP_RESPONSE containing
                  status_code set to "201 Created",
                  Location set to LOCATION,
                  Location set to BW_ALLOCATION_ID,
                  body containing
                     bwInfo containing
                        appInsId set to APP_INSTANCE_ID,
@@ -310,7 +309,7 @@ Package MEC_MEC015_SRV_TM {
               // MEC 015 Clause 8.4.3.4
               the IUT entity sends a HTTP_RESPONSE containing
                  status_code set to "201 Created",
                  Location set to LOCATION,
                  Location indicating value BW_ALLOCATION_ID,
                  body containing
                     bwInfo containing
                        appInsId set to APP_INSTANCE_ID,
@@ -512,7 +511,7 @@ Package MEC_MEC015_SRV_TM {
            then {
               // MEC 015 Clause 8.4.3.1
               the IUT entity sends a HTTP_RESPONSE containing
                  status_code set to "200 OK"
                  status_code set to "200 OK",
                  body containing
                     bwInfo containing
                        appInsId set to APP_INSTANCE_ID
@@ -599,11 +598,10 @@ Package MEC_MEC015_SRV_TM {
            when {
               the IUT entity receives a vPUT containing
                  uri indicating value "bwm/v1/bw_allocations/{ALLOCATION_ID}",
                  if_match indicating value PROPER_ETAG,
                  body containing
                     bwInfo containing
                        appInsId indicating value APP_INSTANCE_ID,
                        fixedAllocation indicating value SOME_ALLOCATION,
                        fixedAllocation indicating value SOME_NEW_ALLOCATION,
                        allocationDirection indicating value SOME_DIRECTION
                     ;
                  ;
@@ -658,7 +656,6 @@ Package MEC_MEC015_SRV_TM {
            when {
               the IUT entity receives a vPUT containing
                  uri indicating value "bwm/v1/bw_allocations/{ALLOCATION_ID}",
                  if_match indicating value PROPER_ETAG,
                  body containing
                     bwInfo containing
                        appInsId indicating value APP_INSTANCE_ID,
@@ -710,7 +707,6 @@ Package MEC_MEC015_SRV_TM {
            when {
               the IUT entity receives a vPUT containing
                  uri indicating value "bwm/v1/bw_allocations/{NON_EXISTENT_ALLOCATION_ID}",
                  if_match indicating value PROPER_ETAG,
                  body containing
                     bwInfo containing
                        appInsId indicating value APP_INSTANCE_ID,
@@ -732,58 +728,6 @@ Package MEC_MEC015_SRV_TM {
   }


   Test Purpose {
      TP Id "TP_MEC_MEC015_SRV_TM_005_PF"

      Test objective
         "Check that the IUT responds with an error when
         a request sent by a MEC Application doesn't comply with a required condition"

      Reference "ETSI GS MEC 015 V2.1.1, clause 8.3.3.2",
                "https://forge.etsi.org/rep/mec/gs015-bandwith-mgmt-api/blob/master/BwManagementApi.yaml"

      Config Id Config_MEC_1

      PICS Selection PIC_MEC_PLAT and PIC_SERVICES

      Initial conditions  with {
         the IUT entity being_in idle_state and
         the MEC_APP entity having a app_instance containing
            appInsId indicating value APP_INSTANCE_ID
         ; and
         the MEC_APP entity having a allocation_instance containing
            allocationId indicating value ALLOCATION_ID
         ;
      }

      // MEC 015 Clause 6.2.4
      Expected behaviour
         ensure that {
            when {
               the IUT entity receives a vPUT containing
                  uri indicating value "bwm/v1/bw_allocations/{ALLOCATION_ID}",
                  if_match indicating value INVALID_ETAG,
                  body containing
                     bwInfo containing
                        appInsId indicating value APP_INSTANCE_ID,
                        fixedAllocation indicating value SOME_ALLOCATION,
                        allocationDirection indicating value SOME_DIRECTION
                     ;
                  ;
               ;
               from the MEC_APP entity
            }
            then {
               // MEC 015 Clause 8.3.3.2
               the IUT entity sends a HTTP_RESPONSE containing
                  status_code set to "412 Precondition Failed"
               ;
               to the MEC_APP entity
            }
         }
   }


   Test Purpose {
      TP Id "TP_MEC_MEC015_SRV_TM_006_OK"

@@ -815,9 +759,8 @@ Package MEC_MEC015_SRV_TM {
            when {
               the IUT entity receives a vPATCH containing
                  uri indicating value "bwm/v1/bw_allocations/{ALLOCATION_ID}",
                  if_match indicating value PROPER_ETAG,
                  body containing
                     bwInfo containing
                     bwInfoDeltas containing
                        appInsId indicating value APP_INSTANCE_ID,
                        fixedAllocation indicating value SOME_ALLOCATION,
                        allocationDirection indicating value SOME_DIRECTION
@@ -874,7 +817,6 @@ Package MEC_MEC015_SRV_TM {
            when {
               the IUT entity receives a vPATCH containing
                  uri indicating value "bwm/v1/bw_allocations/{ALLOCATION_ID}",
                  if_match indicating value PROPER_ETAG,
                  body containing
                     bwInfo containing
                        appInsId indicating value APP_INSTANCE_ID,
@@ -927,7 +869,6 @@ Package MEC_MEC015_SRV_TM {
            when {
               the IUT entity receives a vPATCH containing
                  uri indicating value "bwm/v1/bw_allocations/{NON_EXISTENT_ALLOCATION_ID}",
                  if_match indicating value PROPER_ETAG,
                  body containing
                     bwInfo containing
                        appInsId indicating value APP_INSTANCE_ID,
@@ -949,58 +890,6 @@ Package MEC_MEC015_SRV_TM {
   }


   Test Purpose {
      TP Id "TP_MEC_MEC015_SRV_TM_006_PF"

      Test objective
         "Check that the IUT responds with an error when
         a request sent by a MEC Application doesn't comply with a required condition"

      Reference "ETSI GS MEC 015 V2.1.1, clause 8.3.3.3",
                "https://forge.etsi.org/rep/mec/gs015-bandwith-mgmt-api/blob/master/BwManagementApi.yaml"

      Config Id Config_MEC_1

      PICS Selection PIC_MEC_PLAT and PIC_SERVICES

      Initial conditions  with {
         the IUT entity being_in idle_state and
         the MEC_APP entity having a app_instance containing
            appInsId indicating value APP_INSTANCE_ID
         ; and
         the MEC_APP entity having a allocation_instance containing
            allocationId indicating value ALLOCATION_ID
         ;
      }

      // MEC 015 Clause 6.2.4
      Expected behaviour
         ensure that {
            when {
               the IUT entity receives a vPATCH containing
                  uri indicating value "bwm/v1/bw_allocations/{ALLOCATION_ID}",
                  if_match indicating value INVALID_ETAG,
                  body containing
                     bwInfo containing
                        appInsId indicating value APP_INSTANCE_ID,
                        fixedAllocation indicating value SOME_ALLOCATION,
                        allocationDirection indicating value SOME_DIRECTION
                     ;
                  ;
               ;
               from the MEC_APP entity
            }
            then {
               // MEC 015 Clause 8.3.3.3
               the IUT entity sends a HTTP_RESPONSE containing
                  status_code set to "412 Precondition Failed"
               ;
               to the MEC_APP entity
            }
         }
   }


   Test Purpose {
      TP Id "TP_MEC_MEC015_SRV_TM_007_OK"