diff --git a/automationtests/src/main/java/io/mosip/testrig/apirig/testscripts/DemoAuthSimplePostForAutoGenId.java b/automationtests/src/main/java/io/mosip/testrig/apirig/testscripts/DemoAuthSimplePostForAutoGenId.java index 2ae80b6c8b3..263d4b41877 100644 --- a/automationtests/src/main/java/io/mosip/testrig/apirig/testscripts/DemoAuthSimplePostForAutoGenId.java +++ b/automationtests/src/main/java/io/mosip/testrig/apirig/testscripts/DemoAuthSimplePostForAutoGenId.java @@ -137,6 +137,14 @@ public void test(TestCaseDTO testCaseDTO) String[] templateFields = testCaseDTO.getTemplateFields(); String inputJson = getJsonFromTemplate(input, testCaseDTO.getInputTemplate()); + //Added for dsl demoauth request body changes + String phone = getValueFromAuthActuator("json-property", "phone_number"); + String result = phone.replaceAll("\\[\"|\"\\]", ""); + String email = getValueFromAuthActuator("json-property", "emailId"); + String emailResult = email.replaceAll("\\[\"|\"\\]", ""); + inputJson = inputJson.replace("\"phone\":", "\"" + result + "\":"); + inputJson = inputJson.replace("\"email\":", "\"" + emailResult + "\":"); + String outputJson = getJsonFromTemplate(testCaseDTO.getOutput(), testCaseDTO.getOutputTemplate()); if (testCaseDTO.getTemplateFields() != null && templateFields.length > 0) {