Skip to content
010_02.json 3.27 KiB
Newer Older
lopezaguilar's avatar
lopezaguilar committed
{
lopezaguilar's avatar
lopezaguilar committed
  "tp_id": "TP/NGSI-LD/CI/Prov/EA/010_02",
lopezaguilar's avatar
lopezaguilar committed
  "test_objective": "Check that you cannot append entity attributes with invalid/missing id or invalid request body",
  "reference": "ETSI GS CIM 009 V1.3.1 [], clause 5.6.3",
  "config_id": "",
  "parent_release": "v1.3.1",
  "clauses": [
    "5.6.3"
  ],
  "pics_selection": "",
lopezaguilar's avatar
lopezaguilar committed
  "keywords": [],
  "teardown": "None",
  "initial_condition": "with {\n    the SUT being in the \"initial state\" and\n    the SUT containing an initial Entity ${entity} \n        with an id set to ${entityId} \n}",
lopezaguilar's avatar
lopezaguilar committed
  "test_cases": [
    {
      "name": "010_02_01 Append entity attributes if the entity Id is not present",
lopezaguilar's avatar
lopezaguilar committed
      "permutation_tp_id": "TP/NGSI-LD/CI/Prov/EA/010_02_01",
lopezaguilar's avatar
lopezaguilar committed
      "doc": "Check that you cannot append entity attributes with invalid/missing id or invalid request body",
      "tags": [
        "ea-append",
        "5_6_3"
      ],
      "setup": "Create Initial Entity",
      "teardown": "Delete Initial Entity",
lopezaguilar's avatar
lopezaguilar committed
      "template": "Append Attributes",
      "then": "then {\n    the SUT sends a valid Response for the operations:\n        Append Entity Attributes with Response Status Code set to 400     and\n        Append Entity Attributes with Response Body containing the type 'https://uri.etsi.org/ngsi-ld/errors/BadRequestData'     and\n        Append Entity Attributes with Response body containing 'title' element\n}",
lopezaguilar's avatar
lopezaguilar committed
      "when": "when {\n    the SUT receives a Request from the client containing:\n        URL set to '/ngsi-ld/v1/entities/{id}/attrs'\n        method set to 'POST'\n        Append Entity Attributes and\n    Query Parameter: id set to '${EMPTY}' and\n    Query Parameter: fragment_filename set to 'vehicle-attribute-to-add-fragment.jsonld' and\n    Query Parameter: content_type set to 'application/ld+json'\n}",
      "http_verb": "POST",
      "endpoint": "entities/{id}/attrs"
    },
    {
      "name": "010_02_02 Append entity attributes if the Entity Id is not a valid URI",
lopezaguilar's avatar
lopezaguilar committed
      "permutation_tp_id": "TP/NGSI-LD/CI/Prov/EA/010_02_02",
lopezaguilar's avatar
lopezaguilar committed
      "doc": "Check that you cannot append entity attributes with invalid/missing id or invalid request body",
      "tags": [
        "ea-append",
        "5_6_3"
      ],
      "setup": "Create Initial Entity",
      "teardown": "Delete Initial Entity",
lopezaguilar's avatar
lopezaguilar committed
      "template": "Append Attributes",
      "then": "then {\n    the SUT sends a valid Response for the operations:\n        Append Entity Attributes with Response Status Code set to 400     and\n        Append Entity Attributes with Response Body containing the type 'https://uri.etsi.org/ngsi-ld/errors/BadRequestData'     and\n        Append Entity Attributes with Response body containing 'title' element\n}",
lopezaguilar's avatar
lopezaguilar committed
      "when": "when {\n    the SUT receives a Request from the client containing:\n        URL set to '/ngsi-ld/v1/entities/{id}/attrs'\n        method set to 'POST'\n        Append Entity Attributes and\n    Query Parameter: id set to 'thisisaninvaliduri' and\n    Query Parameter: fragment_filename set to 'vehicle-attribute-to-add-fragment.jsonld' and\n    Query Parameter: content_type set to 'application/ld+json'\n}",
      "http_verb": "POST",
      "endpoint": "entities/{id}/attrs"
    }
  ],
  "permutations": [
    "when"
  ],
  "robotpath": "ContextInformation/Provision/EntityAttributes/AppendEntityAttributes",
  "robotfile": "010_02"
}