From 08a78738c40598fb6ed2be42b39770f2584ab535 Mon Sep 17 00:00:00 2001 From: ManasaBM Date: Tue, 7 Nov 2023 09:41:31 +0100 Subject: [PATCH 1/3] pull request for issue #800 #805 #916 #915 --- testing/ApplicationPattern+testcases.json | 66 +++++++++++++++-------- 1 file changed, 45 insertions(+), 21 deletions(-) diff --git a/testing/ApplicationPattern+testcases.json b/testing/ApplicationPattern+testcases.json index 41c80c49..817dda2e 100644 --- a/testing/ApplicationPattern+testcases.json +++ b/testing/ApplicationPattern+testcases.json @@ -1,6 +1,6 @@ { "info": { - "_postman_id": "e75b1589-fe3d-4730-a491-eaaa0b9b2489", + "_postman_id": "27445677-a0a7-4ce6-bd60-9f9550bbcfcf", "name": "ApplicationPattern+testcases", "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", "_exporter_id": "16731944" @@ -26763,6 +26763,8 @@ "\r", " let foundAnEntryWithTheExpectedHeaderValuesInEatl;\r", " foundAnEntryWithTheExpectedHeaderValuesInEatl = false;\r", + " let responseCodeofTriggeredForwarding;\r", + " responseCodeofTriggeredForwarding = 0;\r", " for(let i=0; i Date: Mon, 13 Nov 2023 05:52:10 +0100 Subject: [PATCH 2/3] formating the code --- testing/ApplicationPattern+testcases.json | 29 ++++++++++++----------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/testing/ApplicationPattern+testcases.json b/testing/ApplicationPattern+testcases.json index 817dda2e..f87dfa4c 100644 --- a/testing/ApplicationPattern+testcases.json +++ b/testing/ApplicationPattern+testcases.json @@ -1,6 +1,6 @@ { "info": { - "_postman_id": "27445677-a0a7-4ce6-bd60-9f9550bbcfcf", + "_postman_id": "ec623b89-3178-4bb5-8555-dd4bac3d7836", "name": "ApplicationPattern+testcases", "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", "_exporter_id": "16731944" @@ -26763,7 +26763,7 @@ "\r", " let foundAnEntryWithTheExpectedHeaderValuesInEatl;\r", " foundAnEntryWithTheExpectedHeaderValuesInEatl = false;\r", - " let responseCodeofTriggeredForwarding;\r", + " let responseCodeofTriggeredForwarding;\r", " responseCodeofTriggeredForwarding = 0;\r", " for(let i=0; i Date: Mon, 20 Nov 2023 12:41:24 +0100 Subject: [PATCH 3/3] adding put http-c-application-name to register-yourself --- testing/ApplicationPattern+testcases.json | 220 +++++++++++++++++++++- 1 file changed, 218 insertions(+), 2 deletions(-) diff --git a/testing/ApplicationPattern+testcases.json b/testing/ApplicationPattern+testcases.json index f87dfa4c..c1ed1618 100644 --- a/testing/ApplicationPattern+testcases.json +++ b/testing/ApplicationPattern+testcases.json @@ -1,9 +1,9 @@ { "info": { - "_postman_id": "ec623b89-3178-4bb5-8555-dd4bac3d7836", + "_postman_id": "f2f8bb0b-48a4-4161-af3f-bb66666b9bff", "name": "ApplicationPattern+testcases", "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", - "_exporter_id": "16731944" + "_exporter_id": "16731944" }, "item": [ { @@ -63280,6 +63280,114 @@ }, "response": [] }, + { + "name": "initial http-c/application-name", + "event": [ + { + "listen": "prerequest", + "script": { + "exec": [ + "/****************************************************************************************\r", + "* Loading Input Data\r", + "****************************************************************************************/\r", + "var APPLICATION;\r", + "var oldReleaseHttpClientLtpUuid;\r", + "var initialApplicationName;\r", + "try {\r", + " APPLICATION = pm.environment.get(\"application\");\r", + " \r", + " let oldReleaseHttpClientLtp;\r", + " oldReleaseHttpClientLtp = pm.collectionVariables.get(\"oldReleaseHttpClientLtp\");\r", + "\r", + " oldReleaseHttpClientLtpUuid = oldReleaseHttpClientLtp[\"uuid\"];\r", + " initialApplicationName = oldReleaseHttpClientLtp[\"layer-protocol\"][0][\"http-client-interface-1-0:http-client-interface-pac\"][\"http-client-interface-configuration\"][\"application-name\"];\r", + "\r", + "} catch (error) {\r", + " console.log(\"! Variables could not be loaded.\");\r", + "}\r", + "\r", + "/****************************************************************************************\r", + "* Setting Collection Variables\r", + "****************************************************************************************/\r", + "\r", + "/****************************************************************************************\r", + "* Setting Local Variables and Preparing the Request\r", + "****************************************************************************************/\r", + "try {\r", + " let URI;\r", + " URI = APPLICATION.serverUrl \r", + " + \"/core-model-1-4:control-construct/logical-termination-point=\"\r", + " + oldReleaseHttpClientLtpUuid\r", + " + \"/layer-protocol=0/http-client-interface-1-0:http-client-interface-pac/http-client-interface-configuration/application-name\";\r", + "\r", + " let REQUEST_BODY;\r", + " REQUEST_BODY = '{ '\r", + " + '\"http-client-interface-1-0:application-name\": \"' + initialApplicationName + '\"'\r", + " + ' }';\r", + "\r", + " let AUTHORIZATION;\r", + " AUTHORIZATION = APPLICATION.authorizationCode;\r", + "\r", + " let ACCEPT;\r", + " ACCEPT = \"application/json\";\r", + "\r", + " let CONTENT_TYPE;\r", + " CONTENT_TYPE = \"application/json\";\r", + "\r", + "\r", + " pm.variables.clear();\r", + "\r", + " pm.variables.set(\"uri\", URI);\r", + " pm.variables.set(\"requestBody\", REQUEST_BODY);\r", + "\r", + " pm.request.headers.upsert({key:\"Authorization\", value:AUTHORIZATION});\r", + "\r", + " pm.request.headers.upsert({key:\"Accept\", value:ACCEPT});\r", + " pm.request.headers.upsert({key:\"Content-Type\", value:CONTENT_TYPE});\r", + "\r", + "} catch (error) {\r", + " console.log(error)\r", + " console.log(\"! Local variables could not be set.\");\r", + "}\r", + "\r", + "\r", + "/****************************************************************************************\r", + "* Functions\r", + "****************************************************************************************/\r", + "\r", + "" + ], + "type": "text/javascript" + } + } + ], + "request": { + "method": "PUT", + "header": [ + { + "key": "x-mock-response-code", + "value": "204", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{{requestBody}}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": { + "raw": "{{uri}}", + "host": [ + "{{uri}}" + ] + } + }, + "response": [] + }, { "name": "initial http-c/release-number", "event": [ @@ -85398,6 +85506,114 @@ }, "response": [] }, + { + "name": "initial http-c/application-name", + "event": [ + { + "listen": "prerequest", + "script": { + "exec": [ + "/****************************************************************************************\r", + "* Loading Input Data\r", + "****************************************************************************************/\r", + "var APPLICATION;\r", + "var oldReleaseHttpClientLtpUuid;\r", + "var initialApplicationName;\r", + "try {\r", + " APPLICATION = pm.environment.get(\"application\");\r", + " \r", + " let oldReleaseHttpClientLtp;\r", + " oldReleaseHttpClientLtp = pm.collectionVariables.get(\"oldReleaseHttpClientLtp\");\r", + "\r", + " oldReleaseHttpClientLtpUuid = oldReleaseHttpClientLtp[\"uuid\"];\r", + " initialApplicationName = oldReleaseHttpClientLtp[\"layer-protocol\"][0][\"http-client-interface-1-0:http-client-interface-pac\"][\"http-client-interface-configuration\"][\"application-name\"];\r", + "\r", + "} catch (error) {\r", + " console.log(\"! Variables could not be loaded.\");\r", + "}\r", + "\r", + "/****************************************************************************************\r", + "* Setting Collection Variables\r", + "****************************************************************************************/\r", + "\r", + "/****************************************************************************************\r", + "* Setting Local Variables and Preparing the Request\r", + "****************************************************************************************/\r", + "try {\r", + " let URI;\r", + " URI = APPLICATION.serverUrl \r", + " + \"/core-model-1-4:control-construct/logical-termination-point=\"\r", + " + oldReleaseHttpClientLtpUuid\r", + " + \"/layer-protocol=0/http-client-interface-1-0:http-client-interface-pac/http-client-interface-configuration/application-name\";\r", + "\r", + " let REQUEST_BODY;\r", + " REQUEST_BODY = '{ '\r", + " + '\"http-client-interface-1-0:application-name\": \"' + initialApplicationName + '\"'\r", + " + ' }';\r", + "\r", + " let AUTHORIZATION;\r", + " AUTHORIZATION = APPLICATION.authorizationCode;\r", + "\r", + " let ACCEPT;\r", + " ACCEPT = \"application/json\";\r", + "\r", + " let CONTENT_TYPE;\r", + " CONTENT_TYPE = \"application/json\";\r", + "\r", + "\r", + " pm.variables.clear();\r", + "\r", + " pm.variables.set(\"uri\", URI);\r", + " pm.variables.set(\"requestBody\", REQUEST_BODY);\r", + "\r", + " pm.request.headers.upsert({key:\"Authorization\", value:AUTHORIZATION});\r", + "\r", + " pm.request.headers.upsert({key:\"Accept\", value:ACCEPT});\r", + " pm.request.headers.upsert({key:\"Content-Type\", value:CONTENT_TYPE});\r", + "\r", + "} catch (error) {\r", + " console.log(error)\r", + " console.log(\"! Local variables could not be set.\");\r", + "}\r", + "\r", + "\r", + "/****************************************************************************************\r", + "* Functions\r", + "****************************************************************************************/\r", + "\r", + "" + ], + "type": "text/javascript" + } + } + ], + "request": { + "method": "PUT", + "header": [ + { + "key": "x-mock-response-code", + "value": "204", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{{requestBody}}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": { + "raw": "{{uri}}", + "host": [ + "{{uri}}" + ] + } + }, + "response": [] + }, { "name": "initial http-c/release-number", "event": [