From b4f5cf16b2bf8ac8a112a8275c58338f6ee7fb58 Mon Sep 17 00:00:00 2001 From: Ravi Chandra <149189748+ravichandra1998g@users.noreply.github.com> Date: Thu, 2 Oct 2025 12:32:28 +0530 Subject: [PATCH] =?UTF-8?q?Revert=20"Add=20Custom=20Test=20Step=20Configur?= =?UTF-8?q?ation=20Script=20to=20Fetch=20Number=20&=20Short=20Des=E2=80=A6?= =?UTF-8?q?"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit fb62c37e501e5fa062f9b144c85662d91bc24337. --- .../Get_Number_&_Short_Description | 18 ------------------ Custom Test Step/Readme.md | 3 --- 2 files changed, 21 deletions(-) delete mode 100644 Custom Test Step/Get_Number_&_Short_Description delete mode 100644 Custom Test Step/Readme.md diff --git a/Custom Test Step/Get_Number_&_Short_Description b/Custom Test Step/Get_Number_&_Short_Description deleted file mode 100644 index 8c9c4ec119..0000000000 --- a/Custom Test Step/Get_Number_&_Short_Description +++ /dev/null @@ -1,18 +0,0 @@ -(function executeStep(inputs, outputs, stepResult, timeout) { - - var recordSysId = inputs.u_sys_id; // It takes the sys_id of the incident - - var finance = new GlideRecord("incident"); - finance.addQuery("sys_id", recordSysId); - finance.query(); - if (finance.next()) { - outputs.u_number = finance.getDisplayValue("number"); - outputs.u_short_description= finance.getDisplayValue("short_description"); - stepResult.setOutputMessage('Found the record'); - stepResult.setSuccess(); // Setting the output message as successfull. - } else { - stepResult.setOutputMessage('Record not found'); - stepResult.setFailed(); // Setting the output message as unsuccessfull. - } - -}(inputs, outputs, stepResult, timeout)); diff --git a/Custom Test Step/Readme.md b/Custom Test Step/Readme.md deleted file mode 100644 index 0a8417a47b..0000000000 --- a/Custom Test Step/Readme.md +++ /dev/null @@ -1,3 +0,0 @@ -Above custom test step configuration script will help to get the "Number" & "Short Description" based on the sys_id of the incident. Let's say while performing any server dependent steps on incident table this custom step configuration script can be very usefullt to retrieve the details, not only about incident or number, short_description. Anybody can utilize this script to create custom step configuration script on different usecases or scenario. - -Note: You need to define the inputs & outputs for this, in my case I have defined the 'sys_id' as an input and "Number" & "Short Description" as an output to store the values and use it anywhere. Also to make sure you define the "stepResult.setOutputMessage("Successfull")" and "stepResult.setOutputMessage("Unsuccessfull")".